This commit is contained in:
Official Noob
2020-01-01 14:50:05 +00:00
committed by GitHub
parent 6c4d5c0705
commit 1d2b6b2010

View File

@@ -43,7 +43,7 @@ chrome.runtime.onMessage.addListener(function (request, sender, callback) {
//add help page on install //add help page on install
chrome.runtime.onInstalled.addListener(function (object) { chrome.runtime.onInstalled.addListener(function (object) {
setTimeout(function() { setTimeout(function() {
const userID = result.userID; const userID = SB.config.userID;
// If there is no userID, then it is the first install. // If there is no userID, then it is the first install.
if (!userID){ if (!userID){
@@ -92,8 +92,7 @@ function addSponsorTime(time, videoID, callback) {
} }
function submitVote(type, UUID, callback) { function submitVote(type, UUID, callback) {
chrome.storage.sync.get(["userID"], function(result) { let userID = SB.config.userID;
let userID = result.userID;
if (userID == undefined || userID === "undefined") { if (userID == undefined || userID === "undefined") {
//generate one //generate one
@@ -121,7 +120,6 @@ function submitVote(type, UUID, callback) {
}); });
} }
}) })
})
} }
async function submitTimes(videoID, callback) { async function submitTimes(videoID, callback) {