Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit83416f8

Browse files
sheche@microsoft.comsheche@microsoft.com
sheche@microsoft.com
authored and
sheche@microsoft.com
committed
add check for default language
1 parent927481a commit83416f8

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

‎src/commands/show.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,10 @@ export async function searchProblem(channel: vscode.OutputChannel): Promise<void
3838
asyncfunctionshowProblemInternal(channel:vscode.OutputChannel,id:string):Promise<void>{
3939
try{
4040
constleetCodeConfig:vscode.WorkspaceConfiguration=vscode.workspace.getConfiguration("leetcode");
41-
constdefaultLanguage=leetCodeConfig.get<string>("defaultLanguage");
41+
letdefaultLanguage=leetCodeConfig.get<string>("defaultLanguage");
42+
if(defaultLanguage&&languages.indexOf(defaultLanguage)<0){
43+
defaultLanguage=undefined;
44+
}
4245
constlanguage:string|undefined=defaultLanguage||awaitvscode.window.showQuickPick(languages,{placeHolder:"Select the language you want to use"});
4346
if(!language){
4447
return;

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp