@@ -104,23 +104,23 @@ function importAddon() {
104104 if ( process . arch === 'x64' ) {
105105 try {
106106 return require ( 'node-nowplaying-win32-x64-msvc' )
107- } catch ( e ) {
107+ } catch {
108108 log ( 'Failed to import native addon' , 'Native' )
109109 return null
110110 }
111111 }
112112 } else if ( process . platform === 'darwin' ) {
113113 try {
114114 return require ( 'node-nowplaying-darwin-universal' )
115- } catch ( e ) {
115+ } catch {
116116 log ( 'Failed to import native addon' , 'Native' )
117117 return null
118118 }
119119 } else if ( process . platform === 'linux' ) {
120120 if ( process . arch === 'x64' ) {
121121 try {
122122 return require ( 'node-nowplaying-linux-x64-gnu' )
123- } catch ( e ) {
123+ } catch {
124124 log ( 'Failed to import native addon' , 'Native' )
125125 return null
126126 }
@@ -180,17 +180,14 @@ export function filterData(data: NowPlayingMessage): PlaybackData | null {
180180 return playbackData
181181}
182182
183- interface NativeConfig { }
184-
185183class NativeHandler extends BasePlaybackHandler {
186184 name : string = 'native'
187185 requiresInternet : boolean = false
188186
189- config : NativeConfig | null = null
190187 instance : NowPlaying | null = null
191188 current : NowPlayingMessage | null = null
192189
193- async setup ( config : NativeConfig ) : Promise < void > {
190+ async setup ( ) : Promise < void > {
194191 log ( 'Setting up' , 'Native' )
195192
196193 const addon = importAddon ( )
@@ -209,7 +206,6 @@ class NativeHandler extends BasePlaybackHandler {
209206 await instance . subscribe ( )
210207
211208 this . instance = instance
212- this . config = config
213209 }
214210
215211 async cleanup ( ) : Promise < void > {
@@ -220,9 +216,7 @@ class NativeHandler extends BasePlaybackHandler {
220216 this . removeAllListeners ( )
221217 }
222218
223- async validateConfig ( config : unknown ) : Promise < boolean > {
224- const { } = config as NativeConfig
225-
219+ async validateConfig ( ) : Promise < boolean > {
226220 return true
227221 }
228222
0 commit comments