@@ -18,7 +18,6 @@ import {
1818 CodeActionKind ,
1919} from 'vscode-languageserver-types'
2020import { lint , LintResult } from 'sqlint'
21- import log4js from 'log4js'
2221import { RawConfig } from 'sqlint'
2322import cache from './cache'
2423import { complete } from './complete'
@@ -27,19 +26,15 @@ import createConnection from './createConnection'
2726import SettingStore , { Connection as SettingConnection } from './SettingStore'
2827import { Schema } from './database_libs/AbstractClient'
2928import getDatabaseClient from './database_libs/getDatabaseClient'
30- import initializeLogging from './initializeLogging'
3129import { RequireSqlite3Error } from './database_libs/Sqlite3Client'
30+ import { stubLogger } from './logger'
3231
3332export type ConnectionMethod = 'node-ipc' | 'stdio'
3433
3534const TRIGGER_CHARATER = '.'
3635
37- export function createServerWithConnection (
38- connection : Connection ,
39- debug = false
40- ) {
41- initializeLogging ( debug )
42- const logger = log4js . getLogger ( )
36+ export function createServerWithConnection ( connection : Connection ) {
37+ const logger = stubLogger ( )
4338 const documents = new TextDocuments ( TextDocument )
4439 documents . listen ( connection )
4540 let schema : Schema = { tables : [ ] , functions : [ ] }
@@ -396,5 +391,5 @@ export function createServer(
396391 params : { method ?: ConnectionMethod ; debug ?: boolean } = { }
397392) {
398393 const connection : Connection = createConnection ( params . method ?? 'node-ipc' )
399- return createServerWithConnection ( connection , params . debug )
394+ return createServerWithConnection ( connection )
400395}
0 commit comments