@justair/justair-library 4.2.0-beta → 4.2.0-delta
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/models/alerts.js +2 -2
package/package.json
CHANGED
package/src/models/alerts.js
CHANGED
|
@@ -60,6 +60,8 @@ const alertsAuditSchema = mongoose.Schema(
|
|
|
60
60
|
}
|
|
61
61
|
);
|
|
62
62
|
|
|
63
|
+
const AlertsAudit = mongoose.model("AlertsAudit", alertsAuditSchema);
|
|
64
|
+
|
|
63
65
|
// Pre-hook to log single alert deletions
|
|
64
66
|
alertsSchema.pre("findOneAndDelete", async function () {
|
|
65
67
|
const docToDelete = await this.model.findOne(this.getFilter());
|
|
@@ -166,8 +168,6 @@ alertsSchema.pre("updateMany", async function () {
|
|
|
166
168
|
}
|
|
167
169
|
});
|
|
168
170
|
|
|
169
|
-
const AlertsAudit = mongoose.model("Audit", alertsAuditSchema);
|
|
170
|
-
|
|
171
171
|
const Alerts = mongoose.model("Alerts", alertsSchema);
|
|
172
172
|
|
|
173
173
|
export { alertsSchema, Alerts, AlertsAudit, alertsAuditSchema };
|