Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Corrected signature for identity.getAuthToken #31

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions chrome-extension-async.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3306,13 +3306,13 @@ declare namespace chrome.i18n {

/** Holds detected ISO language code and its percentage in the input string */
interface DetectedLanguage {
/** An ISO language code such as 'en' or 'fr'.
* For a complete list of languages supported by this method, see [kLanguageInfoTable]{@link https://src.chromium.org/viewvc/chrome/trunk/src/third_party/cld/languages/internal/languages.cc}.
/** An ISO language code such as 'en' or 'fr'.
* For a complete list of languages supported by this method, see [kLanguageInfoTable]{@link https://src.chromium.org/viewvc/chrome/trunk/src/third_party/cld/languages/internal/languages.cc}.
* For an unknown language, 'und' will be returned, which means that [percentage] of the text is unknown to CLD */
language: string;

/** The percentage of the detected language */
percentage: number;
percentage: number;
}

/** Holds detected language reliability and array of DetectedLanguage */
Expand Down Expand Up @@ -3428,7 +3428,7 @@ declare namespace chrome.identity {
* If you specify the callback parameter, it should be a function that looks like this:
* function(string token) {...};
*/
export function getAuthToken(details: TokenDetails, callback?: (token: string) => void): Promise<string>;
export function getAuthToken(details: TokenDetails, callback?: (token?: string, grantedScopes?: string[]) => void): Promise<[string?, string[]?]>;
/**
* Retrieves email address and obfuscated gaia id of the user signed into a profile.
* This API is different from identity.getAccounts in two ways. The information returned is available offline, and it only applies to the primary account for the profile.
Expand Down Expand Up @@ -5605,7 +5605,7 @@ declare namespace chrome.storage {
////////////////////
// Socket
////////////////////
/** Use the chrome.socket API to send and receive data over the network using TCP and UDP connections.
/** Use the chrome.socket API to send and receive data over the network using TCP and UDP connections.
* Note: Starting with Chrome 33, this API is deprecated in favor of the sockets.udp, sockets.tcp and sockets.tcpServer APIs.
* @since Chrome 24.
* @deprecated Chrome 33. */
Expand Down Expand Up @@ -7706,4 +7706,4 @@ declare namespace chrome.windows {
* Note: On some Linux window managers, WINDOW_ID_NONE will always be sent immediately preceding a switch from one chrome window to another.
*/
var onFocusChanged: WindowIdEvent;
}
}