fix: Fixes an exception when the chat button and shortcut are clicked.
This commit is contained in:
parent
64c5ae1c48
commit
a3cb081609
|
@ -642,11 +642,16 @@ UI.toggleFilmstrip = function() {
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Indicates if the filmstrip is currently visible or not.
|
* Checks if the filmstrip is currently visible or not.
|
||||||
* @returns {true} if the filmstrip is currently visible, otherwise
|
* @returns {true} if the filmstrip is currently visible, and false otherwise.
|
||||||
*/
|
*/
|
||||||
UI.isFilmstripVisible = () => Filmstrip.isFilmstripVisible();
|
UI.isFilmstripVisible = () => Filmstrip.isFilmstripVisible();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @returns {true} if the chat panel is currently visible, and false otherwise.
|
||||||
|
*/
|
||||||
|
UI.isChatVisible = () => Chat.isVisible();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Toggles chat panel.
|
* Toggles chat panel.
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -104,7 +104,7 @@ export default function getDefaultButtons() {
|
||||||
sendAnalytics(createToolbarEvent(
|
sendAnalytics(createToolbarEvent(
|
||||||
'toggle.chat',
|
'toggle.chat',
|
||||||
{
|
{
|
||||||
enable: !APP.UI.Chat.isVisible()
|
enable: !APP.UI.isChatVisible()
|
||||||
}));
|
}));
|
||||||
APP.UI.emitEvent(UIEvents.TOGGLE_CHAT);
|
APP.UI.emitEvent(UIEvents.TOGGLE_CHAT);
|
||||||
},
|
},
|
||||||
|
@ -117,7 +117,7 @@ export default function getDefaultButtons() {
|
||||||
sendAnalytics(createShortcutEvent(
|
sendAnalytics(createShortcutEvent(
|
||||||
'toggle.chat',
|
'toggle.chat',
|
||||||
{
|
{
|
||||||
enable: !APP.UI.Chat.isVisible()
|
enable: !APP.UI.isChatVisible()
|
||||||
}));
|
}));
|
||||||
APP.UI.toggleChat();
|
APP.UI.toggleChat();
|
||||||
},
|
},
|
||||||
|
|
Loading…
Reference in New Issue