mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-28 12:33:35 +01:00
#132192 add some trace statements
This commit is contained in:
@@ -6,6 +6,7 @@
|
||||
import { VSBuffer } from 'vs/base/common/buffer';
|
||||
import { CancellationToken } from 'vs/base/common/cancellation';
|
||||
import { IStringDictionary } from 'vs/base/common/collections';
|
||||
import { getErrorMessage } from 'vs/base/common/errors';
|
||||
import { Event } from 'vs/base/common/event';
|
||||
import { parse } from 'vs/base/common/json';
|
||||
import { applyEdits } from 'vs/base/common/jsonEdit';
|
||||
@@ -272,6 +273,7 @@ export class GlobalStateSynchroniser extends AbstractSynchroniser implements IUs
|
||||
}
|
||||
|
||||
private async getLocalGlobalState(): Promise<IGlobalState> {
|
||||
this.logService.trace('GlobalStateSync#getLocalGlobalState');
|
||||
const storage: IStringDictionary<IStorageValue> = {};
|
||||
const argvContent: string = await this.getLocalArgvContent();
|
||||
const argvValue: IStringDictionary<any> = parse(argvContent);
|
||||
@@ -291,9 +293,12 @@ export class GlobalStateSynchroniser extends AbstractSynchroniser implements IUs
|
||||
|
||||
private async getLocalArgvContent(): Promise<string> {
|
||||
try {
|
||||
this.logService.trace('GlobalStateSync#getLocalArgvContent', this.environmentService.argvResource);
|
||||
const content = await this.fileService.readFile(this.environmentService.argvResource);
|
||||
return content.value.toString();
|
||||
} catch (error) { }
|
||||
} catch (error) {
|
||||
this.logService.trace(getErrorMessage(error));
|
||||
}
|
||||
return '{}';
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user