1
0
Fork 0
mirror of https://github.com/FrankerFaceZ/FrankerFaceZ.git synced 2025-10-19 01:12:00 +00:00

Clean up a bunch of linting stuff. Clean up event listeners in tooltips to stop potential memory leaks.

This commit is contained in:
SirStendec 2018-04-02 03:30:22 -04:00
parent f506b512b4
commit 7ecd45fcfb
23 changed files with 70 additions and 79 deletions

View file

@ -1,5 +1,7 @@
'use strict';
/* global emoteMenu: false */
// ============================================================================
// Compatibility Layer
// Emote Menu for Twitch (BTTV Emote Menu)

View file

@ -289,7 +289,7 @@ export default class Directory extends SiteModule {
return;
// Get the old element.
let channel_avatar = card.querySelector('.ffz-channel-avatar');
const channel_avatar = card.querySelector('.ffz-channel-avatar');
if ( ! data || ! data.profileImageURL || setting === 0 ) {
if ( channel_avatar !== null )

View file

@ -56,9 +56,7 @@ export default class HostButton extends Module {
order: 150,
button: true,
disabled: () => {
return this._host_updating || this._host_error;
},
disabled: () => this._host_updating || this._host_error,
click: data => {
if (data.channel) this.sendHostUnhostCommand(data.channel.login);
@ -108,9 +106,9 @@ export default class HostButton extends Module {
} else {
return this.i18n.t('metadata.host.button.tooltip',
'Currently hosting: %{channel}',
{
channel: this._last_hosted_channel || this.i18n.t('metadata.host.button.tooltip.none', 'None')
});
{
channel: this._last_hosted_channel || this.i18n.t('metadata.host.button.tooltip.none', 'None')
});
}
}
};