diff options
author | Ajay <[email protected]> | 2022-08-14 00:14:59 -0400 |
---|---|---|
committer | Ajay <[email protected]> | 2022-08-14 00:14:59 -0400 |
commit | 99c5375c6a4d4c2e4ec072e07cdd0efdc4bad127 (patch) | |
tree | 94141990cce44f2af50117d2213bca773362c5a5 /src/popup.ts | |
parent | fdbcf471493f0fe324715eb3c54a0887c913959b (diff) | |
download | SponsorBlock-99c5375c6a4d4c2e4ec072e07cdd0efdc4bad127.tar.gz SponsorBlock-99c5375c6a4d4c2e4ec072e07cdd0efdc4bad127.zip |
Handle permission userinfo using new logic
Diffstat (limited to 'src/popup.ts')
-rw-r--r-- | src/popup.ts | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/popup.ts b/src/popup.ts index 7b553d96..061634c2 100644 --- a/src/popup.ts +++ b/src/popup.ts @@ -255,7 +255,7 @@ async function runThePopup(messageListener?: MessageListener): Promise<void> { PageElements.showNoticeAgain.style.display = "unset"; } - utils.sendRequestToServer("GET", "/api/userInfo?value=userName&value=viewCount&value=minutesSaved&value=vip&value=canSubmitChapter&userID=" + utils.sendRequestToServer("GET", "/api/userInfo?value=userName&value=viewCount&value=minutesSaved&value=vip&value=permissions&userID=" + Config.config.userID, (res) => { if (res.status === 200) { const userInfo = JSON.parse(res.responseText); @@ -285,7 +285,7 @@ async function runThePopup(messageListener?: MessageListener): Promise<void> { } Config.config.isVip = userInfo.vip; - Config.config.canSubmitChapter = userInfo.canSubmitChapter; + Config.config.permissions = userInfo.permissions; } }); |