Code: enable prettier trailing commas
This commit is contained in:
@@ -3,7 +3,7 @@ import * as lc from 'vscode-languageclient';
|
||||
import { Server } from '../server';
|
||||
import {
|
||||
handle as applySourceChange,
|
||||
SourceChange
|
||||
SourceChange,
|
||||
} from './apply_source_change';
|
||||
|
||||
export async function handle(event: { text: string }): Promise<boolean> {
|
||||
@@ -18,12 +18,12 @@ export async function handle(event: { text: string }): Promise<boolean> {
|
||||
const request: lc.TextDocumentPositionParams = {
|
||||
textDocument: { uri: editor.document.uri.toString() },
|
||||
position: Server.client.code2ProtocolConverter.asPosition(
|
||||
editor.selection.active
|
||||
)
|
||||
editor.selection.active,
|
||||
),
|
||||
};
|
||||
const change = await Server.client.sendRequest<undefined | SourceChange>(
|
||||
'rust-analyzer/onEnter',
|
||||
request
|
||||
request,
|
||||
);
|
||||
if (!change) {
|
||||
return false;
|
||||
|
||||
Reference in New Issue
Block a user