format - extract formatting logic, make it so that we potentially run multiple providers sequentially (off for now)

This commit is contained in:
Johannes Rieken
2018-12-19 15:52:16 +01:00
parent 45d4e2182f
commit 321535761a
3 changed files with 138 additions and 116 deletions

View File

@@ -243,7 +243,7 @@ class FormatOnSaveParticipant implements ISaveParticipantParticipant {
}, timeout);
request.then(edits => this._editorWorkerService.computeMoreMinimalEdits(model.uri, edits)).then(resolve, err => {
if (!(err instanceof Error) || err.name !== NoProviderError.Name) {
if (!NoProviderError.is(err)) {
reject(err);
} else {
resolve();