fix lint @typescript-eslint/ban-types

This commit is contained in:
Johann150
2022-07-04 16:46:48 +02:00
parent d748ba2c51
commit a228d1ddaa
5 changed files with 7 additions and 10 deletions

View File

@@ -1,4 +1,4 @@
export function query(obj: {}): string {
export function query(obj: Record<string, any>): string {
const params = Object.entries(obj)
.filter(([, v]) => Array.isArray(v) ? v.length : v !== undefined)
.reduce((a, [k, v]) => (a[k] = v, a), {} as Record<string, any>);