Uploaded image for project: 'phpBB'
  1. phpBB
  2. PHPBB-13027

PM folder full percentage could be a bit more accurate

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Trivial Trivial
    • 3.1.0-RC5
    • 3.0.12, 3.1.0-RC3
    • None
    • phpbb.com

      "Folder is 100% full (996 from 1000 messages stored)" does not seem too accurate, obviously. The line of code that determines this percentage is in functions_privmsgs.php:

      		'percent'		=> ($user->data['message_limit']) ? (($user->data['message_limit'] > 0) ? round(($folder['num_messages'] / $user->data['message_limit']) * 100) : 100) : 0,

      The use of the round function might not be appropriate here. Perhaps using number_format instead with the second parameter (decimals) being a 1 or a 2?

            nickvergessen Joas Schilling
            DavidIQ David Colón
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: