Skip to content
This repository has been archived by the owner on Jun 27, 2024. It is now read-only.

Commit

Permalink
Update download.js
Browse files Browse the repository at this point in the history
  • Loading branch information
Akkadius committed Jun 3, 2020
1 parent ebc69ee commit cf0aa51
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions app/routes/download.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ router.get('/:downloadType', function (req, res, next) {
fs.mkdirSync(exportPath)
}

let command = 'cd ../ && ./bin/export_client_files ' + downloadType;
let command = 'cd ../ && ./bin/export_client_files ' + downloadType;
const spellsFile = path.join(emuPath, 'export/spells_us.txt');
if (fs.existsSync(spellsFile)) {
const stats = fs.statSync(spellsFile);
Expand Down Expand Up @@ -65,17 +65,17 @@ router.get('/:downloadType', function (req, res, next) {
break;
default:
}


const fs = require('fs');
if (!fs.existsSync(file)) {
res.send("File does not exist");
res.send('File does not exist');
return;
}

/**
* Get base file name
*/
const base_file_name = path.basename(file).replace('.txt', '');
const fs = require('fs');
const yazl = require('yazl');
const zipfile = new yazl.ZipFile();

Expand Down

0 comments on commit cf0aa51

Please sign in to comment.