mirror of
https://github.com/Dahlgren/arma-server-web-admin.git
synced 2024-08-30 17:22:10 +00:00
Fixed issue arising from uploading missions to a server with multi-partitions
This commit is contained in:
parent
0de8b04ee0
commit
b17dc8822c
@ -1,6 +1,6 @@
|
|||||||
var async = require('async');
|
var async = require('async');
|
||||||
var filesize = require('filesize');
|
var filesize = require('filesize');
|
||||||
var fs = require('fs');
|
var fs = require ('fs.extra');
|
||||||
var path = require('path');
|
var path = require('path');
|
||||||
var SteamWorkshop = require('steam-workshop');
|
var SteamWorkshop = require('steam-workshop');
|
||||||
|
|
||||||
@ -48,7 +48,7 @@ Missions.prototype.list = function (cb){
|
|||||||
|
|
||||||
Missions.prototype.handleUpload = function (uploadedFile, cb) {
|
Missions.prototype.handleUpload = function (uploadedFile, cb) {
|
||||||
var filename = decodeURI(uploadedFile.originalname.toLowerCase());
|
var filename = decodeURI(uploadedFile.originalname.toLowerCase());
|
||||||
fs.rename(uploadedFile.path, path.join(this.missionsPath(), filename), function (err) {
|
fs.move (uploadedFile.path, path.join(this.missionsPath(), filename), function (err) {
|
||||||
cb(err);
|
cb(err);
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user