Skip to content

Commit

Permalink
feat: add twitchbot badge for TwirApp
Browse files Browse the repository at this point in the history
  • Loading branch information
crashmax-dev committed Mar 18, 2024
1 parent 227ac66 commit 8423f92
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions src/twir/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,6 @@ class Twir extends Addon {
component: 'setting-check-box',
}
});

this.loadBadges();
}

onEnable() {
Expand Down Expand Up @@ -101,10 +99,10 @@ class Twir extends Addon {
}

updateBadges(enabled) {
if (!enabled) {
this.unloadBadges();
} else {
if (enabled) {
this.loadBadges();
} else {
this.unloadBadges();
}
}

Expand All @@ -117,12 +115,15 @@ class Twir extends Addon {
const showUserBadges = this.settings.get('addon.twir.user_badges');
if (!showUserBadges) return;

// twitchbot badge for TwirApp
this.chat.getUser(870280719).addBadge('ffz', 2);

this.badges.loadBadgeData('addon.twir.badge_contributor', {
id: 'contributor',
name: 'Twir Contributor',
title: 'Twir Contributor',
click_url: 'https://twir.app',
image: 'https://twir.app/twir.svg',
image: 'https://raw.githubusercontent.com/twirapp/twir/main/libs/brand/src/logo.svg',
slot: 100,
svg: true,
});
Expand Down

0 comments on commit 8423f92

Please sign in to comment.