@@ -2,7 +2,7 @@ import * as vscode from 'vscode';
22import { HackMDTreeViewProvider } from './../tree/index' ;
33import { NoteTreeNode } from './../tree/nodes' ;
44import { MdTextDocumentContentProvider } from './../mdTextDocument' ;
5- import { refreshHistoryList , refreshLoginStatus , refreshLoginCredential , getLoginCredential } from './../utils' ;
5+ import { refreshHistoryList , refreshLoginStatus , refreshLoginCredential } from './../utils' ;
66import { API , ExportType } from './../api' ;
77
88export async function registerTreeViewCommands ( context : vscode . ExtensionContext ) {
@@ -25,8 +25,7 @@ export async function registerTreeViewCommands(context: vscode.ExtensionContext)
2525 }
2626 } ) ) ;
2727
28- context . subscriptions . push ( vscode . commands . registerCommand ( 'note.showPreview' , async ( node : NoteTreeNode ) => {
29- const noteNode = node ;
28+ context . subscriptions . push ( vscode . commands . registerCommand ( 'note.showPreview' , async ( noteNode : NoteTreeNode ) => {
3029 if ( noteNode . label && noteNode . noteId ) {
3130 const content = await API . exportString ( noteNode . noteId , ExportType . MD ) ;
3231 if ( content ) {
@@ -36,8 +35,7 @@ export async function registerTreeViewCommands(context: vscode.ExtensionContext)
3635 }
3736 } ) ) ;
3837
39- context . subscriptions . push ( vscode . commands . registerCommand ( 'note.showPreviewAndEditor' , async ( node : NoteTreeNode ) => {
40- const noteNode = node ;
38+ context . subscriptions . push ( vscode . commands . registerCommand ( 'note.showPreviewAndEditor' , async ( noteNode : NoteTreeNode ) => {
4139 if ( noteNode . label && noteNode . noteId ) {
4240 const content = await API . exportString ( noteNode . noteId , ExportType . MD ) ;
4341 if ( content ) {
0 commit comments