fix(server): lint errors

This commit is contained in:
Roberto Tonino 2021-06-01 22:54:46 +02:00
parent 6dfd28f7a9
commit 8d9f79e662
5 changed files with 5 additions and 5 deletions

View File

@ -3,7 +3,7 @@ import { cancelAllDownloads } from '../../../main'
const path = '/cancelAllDownloads' const path = '/cancelAllDownloads'
const handler: ApiHandler['handler'] = async (req, res) => { const handler: ApiHandler['handler'] = (_, res) => {
cancelAllDownloads() cancelAllDownloads()
res.send({ result: true }) res.send({ result: true })
} }

View File

@ -5,7 +5,7 @@ import { sessionDZ } from '../../../main'
const path: ApiHandler['path'] = '/logout' const path: ApiHandler['path'] = '/logout'
const handler: ApiHandler['handler'] = async (req, res) => { const handler: ApiHandler['handler'] = (req, res) => {
sessionDZ[req.session.id] = new Deezer() sessionDZ[req.session.id] = new Deezer()
res.send({ logged_out: true }) res.send({ logged_out: true })
} }

View File

@ -3,7 +3,7 @@ import { clearCompletedDownloads } from '../../../main'
const path = '/removeFinishedDownloads' const path = '/removeFinishedDownloads'
const handler: ApiHandler['handler'] = async (req, res) => { const handler: ApiHandler['handler'] = (_, res) => {
clearCompletedDownloads() clearCompletedDownloads()
res.send({ result: true }) res.send({ result: true })
} }

View File

@ -3,7 +3,7 @@ import { cancelDownload } from '../../../main'
const path = '/removeFromQueue' const path = '/removeFromQueue'
const handler: ApiHandler['handler'] = async (req, res) => { const handler: ApiHandler['handler'] = (req, res) => {
const { uuid } = req.query const { uuid } = req.query
if (uuid) { if (uuid) {
cancelDownload(uuid) cancelDownload(uuid)

View File

@ -8,7 +8,7 @@ export interface SaveSettingsData {
spotifySettings: SpotifySettings spotifySettings: SpotifySettings
} }
const handler: ApiHandler['handler'] = async (req, res) => { const handler: ApiHandler['handler'] = (req, res) => {
const { settings, spotifySettings }: SaveSettingsData = req.query const { settings, spotifySettings }: SaveSettingsData = req.query
saveSettings(settings, spotifySettings) saveSettings(settings, spotifySettings)
listener.send('updateSettings', { settings, spotifySettings }) listener.send('updateSettings', { settings, spotifySettings })