-
Notifications
You must be signed in to change notification settings - Fork 154
Array to string conversion in GUI.class.php getFileNamesForDisplay() #2512
Copy link
Copy link
Closed
Labels
fix mergedA PR has been created and merged to help or address this issueA PR has been created and merged to help or address this issue
Description
The function getFileNamesForDisplay() in classes/utils/GUI.class.php uses $transfer->downloads (an array) where an integer value is expected.
Problem: When viewing the transfers table on FileSender 3.3, PHP throws:
PHP Warning: Array to string conversion in classes/utils/GUI.class.php on line 484
The file name column displays "Array" before the actual filename.
Comparison:
- Line 479 (Incorrect):
$dlcount = $transfer->downloads;(downloads is an array) - Should be:
$dlcount = $transfer->download_count;(download_count is an integer)
Steps to reproduce:
- Upload a file using FileSender 3.3
- Navigate to "My Transfers"
- Observe the file names column in the transfers table
- Check PHP error logs
Suggested Fix: Change$transfer->downloadsto$transfer->download_counton line 479.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
fix mergedA PR has been created and merged to help or address this issueA PR has been created and merged to help or address this issue