mirror of
https://github.com/MichMich/MagicMirror.git
synced 2025-06-27 19:53:36 +00:00
use alert as default in notificationReceived
This commit is contained in:
parent
460a9fc5f7
commit
026e624e23
@ -145,13 +145,10 @@ Module.register("alert", {
|
|||||||
|
|
||||||
notificationReceived(notification, payload, sender) {
|
notificationReceived(notification, payload, sender) {
|
||||||
if (notification === "SHOW_ALERT") {
|
if (notification === "SHOW_ALERT") {
|
||||||
if (typeof payload.type === "undefined") {
|
if (payload.type === "notification") {
|
||||||
payload.type = "alert";
|
|
||||||
}
|
|
||||||
if (payload.type === "alert") {
|
|
||||||
this.showAlert(payload, sender);
|
|
||||||
} else if (payload.type === "notification") {
|
|
||||||
this.showNotification(payload);
|
this.showNotification(payload);
|
||||||
|
} else {
|
||||||
|
this.showAlert(payload, sender);
|
||||||
}
|
}
|
||||||
} else if (notification === "HIDE_ALERT") {
|
} else if (notification === "HIDE_ALERT") {
|
||||||
this.hideAlert(sender);
|
this.hideAlert(sender);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user