mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-02-03 17:23:42 -05:00
Merge from vscode 79a1f5a5ca0c6c53db617aa1fa5a2396d2caebe2
This commit is contained in:
@@ -14,27 +14,27 @@ export class KeytarCredentialsService implements ICredentialsService {
|
||||
private readonly _keytar = new IdleValue<Promise<KeytarModule>>(() => import('keytar'));
|
||||
|
||||
async getPassword(service: string, account: string): Promise<string | null> {
|
||||
const keytar = await this._keytar.getValue();
|
||||
const keytar = await this._keytar.value;
|
||||
return keytar.getPassword(service, account);
|
||||
}
|
||||
|
||||
async setPassword(service: string, account: string, password: string): Promise<void> {
|
||||
const keytar = await this._keytar.getValue();
|
||||
const keytar = await this._keytar.value;
|
||||
return keytar.setPassword(service, account, password);
|
||||
}
|
||||
|
||||
async deletePassword(service: string, account: string): Promise<boolean> {
|
||||
const keytar = await this._keytar.getValue();
|
||||
const keytar = await this._keytar.value;
|
||||
return keytar.deletePassword(service, account);
|
||||
}
|
||||
|
||||
async findPassword(service: string): Promise<string | null> {
|
||||
const keytar = await this._keytar.getValue();
|
||||
const keytar = await this._keytar.value;
|
||||
return keytar.findPassword(service);
|
||||
}
|
||||
|
||||
async findCredentials(service: string): Promise<Array<{ account: string, password: string }>> {
|
||||
const keytar = await this._keytar.getValue();
|
||||
const keytar = await this._keytar.value;
|
||||
return keytar.findCredentials(service);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user