If mp3/image preview is enabled and user go to the download page, the last download is not updated.
So it will be deleted as inactive even though they were played/viewed. Especially the images are vulnerable since not many will push download button.
XFileSharing Pro - Need quick fix for mp3/image preview bug
- PilgrimX182
- Posts: 2186
- Joined: Mar 22, 2006 1:39 pm
Good point, thanks!
In index.cgi find
and add line below:
add same line after
In index.cgi find
Code: Select all
if($c->{image_mod} && $file->{file_name}=~/\.(jpg|jpeg|gif|png|bmp)$/i && $file->{file_size}<1048576*3)
{
Code: Select all
$db->Exec("UPDATE Files SET file_downloads=file_downloads+1, file_last_download=NOW() WHERE file_id=?",$file->{file_id});
Code: Select all
if($c->{mp3_mod} && $file->{file_name}=~/\.mp3$/i && $file->{file_size}<1048576*10 && !$file->{message})
{