Fix typo and possible wrong value on provider is false on generating front-end constants

This commit is contained in:
Wu Cheng-Han 2017-03-20 01:54:44 +08:00
parent 448b006194
commit 19a64f6b06

6
app.js
View file

@ -36,9 +36,9 @@ var data = {
urlpath: config.urlpath,
debug: config.debug,
version: config.version,
GOOGLE_API_KEY: config.google && config.google.GOOGLE_API_KEY,
GOOGLE_CLIENT_ID: config.google && config.google.GOOGLE_CLIENT_ID,
DROPBOX_APP_KEY: config.dropbox && config.google.DROPBOX_APP_KEY
GOOGLE_API_KEY: config.google ? config.google.GOOGLE_API_KEY : '',
GOOGLE_CLIENT_ID: config.google ? config.google.GOOGLE_CLIENT_ID : '',
DROPBOX_APP_KEY: config.dropbox ? config.dropbox.DROPBOX_APP_KEY : ''
}
ejs.renderFile(constpath, data, {}, function (err, str) {
if (err) throw new Error(err)