ImportHandler: early return by condition inversion

No functional changes
This commit is contained in:
muxator 2018-10-31 23:24:56 +01:00
parent 2b8e45e2bd
commit 12bb97dc2d

View file

@ -227,7 +227,12 @@ exports.doImport = function(req, res, padId)
//read the text
function(callback) {
if(!directDatabaseAccess){
if (directDatabaseAccess) {
callback();
return;
}
fs.readFile(destFile, "utf8", function(err, _text){
if(ERR(err, callback)) return;
text = _text;
@ -243,9 +248,6 @@ exports.doImport = function(req, res, padId)
callback();
}
});
}else{
callback();
}
},
//change text of the pad and broadcast the changeset