1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

As Designed Maximum large avatar file size (bytes)

Discussion in 'Resolved Bug Reports' started by Metin Galimidi, Apr 8, 2014.

  1. Hello,
    I am using Xenforo 1.3

    When I set Maximum large avatar file size (bytes): 51200 and upload an avatar image much bigger than that I don't get an error message.

    Set the Maximum large avatar file size (bytes) for a user group as 51200

    Steps to reproduce:
    1. Go to the site
    2. Login
    3. Go to manage account settings
    4. View the copy next to the avatar upload
    5. Upload an image larger than 51200 bytes
    Actual result: Upload is successful, avatar changed

    Expected result : User should get an error saying that the file uploaded is too large.

    Notes: I took a quick peek at Xenforo/Model/Avatar.php and it looks like the comparison is being done against the final output rather than the size of the actual image that is being uploaded. Is this intended please?

    Thanks in advance
    mathieurivest likes this.
  2. Jeremy

    Jeremy XenForo Moderator Staff Member

    The checks are against the final image, post alterations done by the upload process (resize, etc). You will only receive the error if the final image is above the threshold.
  3. Mike

    Mike XenForo Developer Staff Member

    Yes, this is desired. It's designed to prevent files above certain sizes being output/used.

Share This Page