mirror of
https://github.com/NodeBB/NodeBB.git
synced 2026-01-05 15:20:39 +01:00
fix(#9315): api v3 post, put, del JSON
also allow `app.alertError` to be called without an argument also fix `./nodebb build --dev` to actually build in dev mode
This commit is contained in:
committed by
Julian Lam
parent
c5231f10ff
commit
0d59fe3d2b
@@ -95,10 +95,6 @@ nconf.argv(opts).env({
|
||||
separator: '__',
|
||||
});
|
||||
|
||||
const env = program.dev ? 'development' : (process.env.NODE_ENV || 'production');
|
||||
process.env.NODE_ENV = env;
|
||||
global.env = env;
|
||||
|
||||
prestart.setupWinston();
|
||||
|
||||
// Alternate configuration file support
|
||||
@@ -197,6 +193,10 @@ program
|
||||
.description(`Compile static assets ${'(JS, CSS, templates, languages)'.red}`)
|
||||
.option('-s, --series', 'Run builds in series without extra processes')
|
||||
.action((targets, options) => {
|
||||
if (program.dev) {
|
||||
process.env.NODE_ENV = 'development';
|
||||
global.env = 'development';
|
||||
}
|
||||
require('./manage').build(targets.length ? targets : true, options);
|
||||
})
|
||||
.on('--help', () => {
|
||||
|
||||
Reference in New Issue
Block a user