Replacing empty string with null

This commit is contained in:
efarooqui
2021-02-17 11:33:39 -08:00
parent 3e2b9f2a1d
commit d6512e2cde
2 changed files with 2 additions and 2 deletions

View File

@@ -4,7 +4,7 @@ import copy from '../copy/en'
export default ({ config, controller }) => {
let api = Router()
const fileDest = config.EXPORT_FILE_DEST || ""
const fileDest = config.EXPORT_FILE_DEST || null
api.get('/', (req, res) => {
res.json({

View File

@@ -41,7 +41,7 @@ class Controller {
}
retrieveAll (fileDest) {
if (fileDest === '') return Promise.reject(new Error(copy.errors.export.fileMissing))
if (!fileDest) return Promise.reject(new Error(copy.errors.export.fileMissing))
const indexedData = {}
const urls = []