diff --git a/packages/standard-objects/workflow/flows.object.yml b/packages/standard-objects/workflow/flows.object.yml index 65829c408a..3692a09832 100644 --- a/packages/standard-objects/workflow/flows.object.yml +++ b/packages/standard-objects/workflow/flows.object.yml @@ -572,7 +572,7 @@ actions: }, error: function (XMLHttpRequest, textStatus, errorThrown) { console.error(XMLHttpRequest.responseJSON); - toastr.error(jqXHR.responseText); + toastr.error(XMLHttpRequest.responseText); $(document.body).removeClass('loading'); } }; diff --git a/services/service-cloud-init/package.service.js b/services/service-cloud-init/package.service.js index 6ab38eb5e3..07bf1c5ed0 100644 --- a/services/service-cloud-init/package.service.js +++ b/services/service-cloud-init/package.service.js @@ -263,9 +263,7 @@ module.exports = { const settings = this.settings; const spaceId = settings.STEEDOS_CLOUD_SPACE_ID; const apiKey = settings.STEEDOS_CLOUD_API_KEY; - // 未配置环境变量时,不执行初始化,也不报错 - if (!spaceId || !apiKey) - return; + // console.log(chalk.blue('steedos-server.started')); const records = await objectql.getObject('spaces').directFind({top: 1, fields: ['_id'], sort: {created: -1}}); const steedosConfig = objectql.getSteedosConfig(); @@ -274,6 +272,9 @@ module.exports = { }else{ steedosConfig.setTenant({enable_create_tenant : true, enable_register: true}); } + // 未配置环境变量时,不执行初始化,也不报错 + if (!spaceId || !apiKey) + return; const allowInit = await this.allowInit(records); if (!allowInit) { Initializing = false;