Add missing string getter

This commit is contained in:
Alex Holliday committed 2025-05-12 11:38:51 -07:00
1 parent ea64316c55
commit 395cc5db77
3 files changed
+17 -11

No files matched your search

+11 -9
View File
@@ -582,16 +582,18 @@ class MonitorController {
} }
try { try {
const monitor = await Monitor.findOneAndUpdate({ _id: req.params.monitorId }, [ const monitor = await Monitor.findOneAndUpdate(
{ { _id: req.params.monitorId },
$set: { [
isActive: { $not: "$isActive" }, {
status: "$$REMOVE", $set: {
isActive: { $not: "$isActive" },
status: "$$REMOVE",
},
}, },
}, ],
], { new: true }
{ new: true } );
);
monitor.isActive === true monitor.isActive === true
? await this.jobQueue.deleteJob(monitor) ? await this.jobQueue.deleteJob(monitor)
: await this.jobQueue.addJob(monitor._id, monitor); : await this.jobQueue.addJob(monitor._id, monitor);
+2 -2
View File
@@ -158,8 +158,8 @@
"platformRequired": "Platform is required", "platformRequired": "Platform is required",
"testNotificationFailed": "Failed to send test notification", "testNotificationFailed": "Failed to send test notification",
"monitorUpAlert": "Uptime Alert: One of your monitors is back online.\n📌 Monitor: {monitorName}\n📅 Time: {time}\n⚠️ Status: UP\n📟 Status Code: {code}\n\u200B\n", "monitorUpAlert": "Uptime Alert: One of your monitors is back online.\n📌 Monitor: {monitorName}\n📅 Time: {time}\n⚠️ Status: UP\n📟 Status Code: {code}\n\u200B\n",
"monitorDownAlert": "Downtime Alert: One of your monitors went offline.\n📌 Monitor: {monitorName}\n📅 Time: {time}\n⚠️ Status: DOWN\n📟 Status Code: {code}\n\u200B\n", "monitorDownAlert": "Downtime Alert: One of your monitors went offline.\n📌 Monitor: {monitorName}\n📅 Time: {time}\n⚠️ Status: DOWN\n📟 Status Code: {code}\n\u200B\n",
"sendTestEmail": "Test email sent successfully", "sendTestEmail": "Test email sent successfully",
"errorForValidEmailAddress": "A valid recipient email address is required.", "errorForValidEmailAddress": "A valid recipient email address is required.",
"testEmailSubject": "Test Email from Monitoring System" "testEmailSubject": "Test E-mail from Checkmate"
} }
+4
View File
@@ -428,6 +428,10 @@ class StringService {
get dbUserExists() { get dbUserExists() {
return this.translationService.getTranslation("dbUserExists"); return this.translationService.getTranslation("dbUserExists");
} }
get testEmailSubject() {
return this.translationService.getTranslation("testEmailSubject");
}
} }
export default StringService; export default StringService;