mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-25 11:08:51 +01:00
debt - loadOrCreate => resolve
This commit is contained in:
@@ -216,7 +216,7 @@ export class MainThreadDocuments implements MainThreadDocumentsShape {
|
||||
}
|
||||
|
||||
private _doCreateUntitled(resource?: URI, mode?: string, initialValue?: string): Promise<URI> {
|
||||
return this._textFileService.untitled.loadOrCreate({
|
||||
return this._textFileService.untitled.resolve({
|
||||
resource,
|
||||
mode,
|
||||
initialValue,
|
||||
|
||||
@@ -309,7 +309,7 @@ export class MainThreadWebviews extends Disposable implements extHostProtocol.Ma
|
||||
}
|
||||
|
||||
private async retainCustomEditorModel(webviewInput: WebviewInput, resource: URI, viewType: string, capabilities: readonly extHostProtocol.WebviewEditorCapabilities[]) {
|
||||
const model = await this._customEditorService.models.loadOrCreate(webviewInput.getResource(), webviewInput.viewType);
|
||||
const model = await this._customEditorService.models.resolve(webviewInput.getResource(), webviewInput.viewType);
|
||||
|
||||
const existingEntry = this._customEditorModels.get(model);
|
||||
if (existingEntry) {
|
||||
|
||||
Reference in New Issue
Block a user