fix download count on server (#863)
This commit is contained in:
parent
d906e927ed
commit
59ba89262f
3 changed files with 19 additions and 3 deletions
|
@ -21,10 +21,11 @@ module.exports = async function(req, res) {
|
|||
file_stream.destroy();
|
||||
});
|
||||
|
||||
file_stream.on('close', async () => {
|
||||
file_stream.on('end', async () => {
|
||||
if (cancelled) {
|
||||
return;
|
||||
}
|
||||
|
||||
const dl = meta.dl + 1;
|
||||
const dlimit = meta.dlimit;
|
||||
try {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue