Skip to content
Snippets Groups Projects
Commit d83f2d9d authored by Rodrigo Nascimento's avatar Rodrigo Nascimento
Browse files

[FIX] Not showing unread count on electron app’s icon

parent 2f682aa0
No related branches found
No related tags found
No related merge requests found
window.fireGlobalEvent = function _fireGlobalEvent(eventName, params) {
window.dispatchEvent(new CustomEvent(eventName, {detail: params}));
Tracker.autorun((computation) => {
const enabled = RocketChat.settings.get('Iframe_Integration_send_enable');
if (enabled === undefined) {
......@@ -6,7 +8,6 @@ window.fireGlobalEvent = function _fireGlobalEvent(eventName, params) {
}
computation.stop();
if (enabled) {
window.dispatchEvent(new CustomEvent(eventName, {detail: params}));
parent.postMessage({
eventName,
data: params
......@@ -14,3 +15,4 @@ window.fireGlobalEvent = function _fireGlobalEvent(eventName, params) {
}
});
};
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment