clonemeagain / attachment_preview

osTicket Plugin: Allows inline view of attachments
GNU General Public License v2.0
48 stars 16 forks source link

Ticket with attachment throws fatal error #64

Open SoulGit opened 6 months ago

SoulGit commented 6 months ago

Upon trying to open a ticket that I have been working on successfully for about a week now, the below error is thrown. This doesn't occur on all tickets with attachments. Disabling inline preview plugin allows me to open the ticket and from here I can open click on all attachments successfully (so they aren't missing or corrupt). No system updates or reconfigurations. I just had this ticket open a few days ago without issue. Any pointers to troubleshoot further or resolve? 1.18 latest. Thanks!

Fatal error: Uncaught TypeError: Unsupported operand types: string * int in phar:///var/www/html/osTicket/include/plugins/attachment_preview.phar/class.AttachmentPreviewPlugin.php:208 Stack trace: #0 phar:///var/www/html/osTicket/include/plugins/attachment_preview.phar/class.AttachmentPreviewPlugin.php(217): AttachmentPreviewPlugin->{closure}() #1 phar:///var/www/html/osTicket/include/plugins/attachment_preview.phar/class.AttachmentPreviewPlugin.php(281): AttachmentPreviewPlugin->unFormatSize() #2 phar:///var/www/html/osTicket/include/plugins/attachment_preview.phar/class.AttachmentPreviewPlugin.php(147): AttachmentPreviewPlugin->inlineAttachments() #3 phar:///var/www/html/osTicket/include/plugins/attachment_preview.phar/class.AttachmentPreviewPlugin.php(131): AttachmentPreviewPlugin::shutdownHandler() #4 [internal function]: AttachmentPreviewPlugin->{closure}() #5 {main} thrown in phar:///var/www/html/osTicket/include/plugins/attachment_preview.phar/class.AttachmentPreviewPlugin.php on line 208