Skip to content

Commit

Permalink
removed redundant Config row creation
Browse files Browse the repository at this point in the history
  • Loading branch information
Supinic committed Apr 25, 2024
1 parent 35aebba commit fffba8d
Showing 1 changed file with 0 additions and 12 deletions.
12 changes: 0 additions & 12 deletions controllers/twitch.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,18 +37,6 @@ const fetchToken = async () => {
});
}

if (!sb.Config.has("TWITCH_OAUTH_EXPIRATION", false)) {
const row = await sb.Query.getRow("data", "Config");
row.setValues({
Name: "TWITCH_OAUTH_EXPIRATION",
Type: "number",
Editable: true
});

await row.save({ skipLoad: true });
await sb.Config.reloadData();
}

const response = await sb.Got("GenericAPI", {
url: "https://id.twitch.tv/oauth2/token",
method: "POST",
Expand Down

0 comments on commit fffba8d

Please sign in to comment.