Created
October 4, 2013 22:19
-
-
Save tommynyquist/6833785 to your computer and use it in GitHub Desktop.
chrome identity logged in check
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function isLoggedIn(successCallback, failureCallback) { | |
chrome.identity.getAuthToken(function() { | |
if (chrome.runtime.lastError) | |
failureCallback(); | |
else | |
successCallback(); | |
}); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment