diff --git a/server/model/monitor.js b/server/model/monitor.js index 3ad8cfafc..32e9a6d21 100644 --- a/server/model/monitor.js +++ b/server/model/monitor.js @@ -48,14 +48,11 @@ class Monitor extends BeanModel { let obj = { id: this.id, name: this.name, - sendUrl: this.sendUrl, + sendUrl: !!this.sendUrl, + url: this.url, type: this.type, }; - if (this.sendUrl) { - obj.url = this.url; - } - if (showTags) { obj.tags = await this.getTags(); } diff --git a/src/components/MonitorSettingDialog.vue b/src/components/MonitorSettingDialog.vue index e6b2cd1ef..d62003a89 100644 --- a/src/components/MonitorSettingDialog.vue +++ b/src/components/MonitorSettingDialog.vue @@ -10,7 +10,7 @@