File with password lock is not limited by stock

in Download Manager Free

Viewing 4 posts - 1 through 4 (of 4 total)
Oct 3, 2017 at 3:16 am
#63983
Member
Marco Jackson
OP

Hi,
I have created a download and protected it with password. According to the documentation the stock limit should limit the amount of download. I have set the limit to 1 but I can download the file as many times a I want.
See attachment for reference
Please advise
Thank you

Oct 3, 2017 at 7:43 am
#63990
Moderator
Shahriar
Staff

Hi, We will fix the issue in next release of WPDM. For now, you can add the following code in /download-manager/libs/class.Apply.php after line 374,

if( $package['quota'] > 0 && $package['quota'] <= $package['download_count'] ){
                wpdm_download_data("stock-limit.txt", __("Download limit exceeded.",'download-manager'));
                die();
}

https://www.evernote.com/l/AUcxmibQSYFJD4zRhe4mh4ByVjCWD_xOFL0B/image.png

Oct 3, 2017 at 9:07 am
#63994
Member
Marco Jackson
OP

Hi,
I have added those lines of code but the site is crashing after doing that.

Oct 4, 2017 at 7:48 am
#64058
Moderator
Shafayet
Staff

Actually, the stock limit is working fine, the download count doesn’t increase, when you click on download button multiple times in the same session, like repeated click on same download link.

Viewing 4 posts - 1 through 4 (of 4 total)

The topic "File with password lock is not limited by stock" is closed to new replies.