Skip to content

Commit 0260751

Browse files
committed
chore: fix corelib linter errors
1 parent f022603 commit 0260751

File tree

6 files changed

+6
-6
lines changed

6 files changed

+6
-6
lines changed

packages/corelib/src/TranslatableMessage.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ export function interpollateTranslation(key: unknown, ...args: any[]): string {
4444
}
4545

4646
if (typeof args[0] === 'string') {
47+
// eslint-disable-next-line @typescript-eslint/no-base-to-string
4748
return String(key || args[0])
4849
}
4950

packages/corelib/src/error.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -183,7 +183,7 @@ export class UserError implements UserErrorObj {
183183
} else {
184184
return undefined
185185
}
186-
} catch (e: any) {
186+
} catch (_e: any) {
187187
return undefined
188188
}
189189
}

packages/corelib/src/fixUpBlueprintConfig/context.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import {
55
ITranslatableMessage,
66
JSONSchema,
77
} from '@sofie-automation/blueprints-integration'
8-
import objectPath = require('object-path')
8+
import * as objectPath from 'object-path'
99
import { ReadonlyDeep } from 'type-fest'
1010
import { literal, objectPathGet, objectPathSet, clone } from '../lib.js'
1111
import {

packages/corelib/src/lib.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ export function flatten<T>(vals: Array<T[] | undefined>): T[] {
4040
return _.flatten(
4141
vals.filter((v) => v !== undefined),
4242
true
43-
) as T[]
43+
)
4444
}
4545

4646
export function max<T>(vals: T[], iterator: _.ListIterator<T, any>): T | undefined {

packages/corelib/src/mongo.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
import * as _ from 'underscore'
22
import { ProtectedString } from './protectedString.js'
33
import * as objectPath from 'object-path'
4-
// eslint-disable-next-line n/no-extraneous-import
54
import type { Condition, Filter, UpdateFilter } from 'mongodb'
65
import { clone } from './lib.js'
76

@@ -146,7 +145,7 @@ export function mongoWhere<T>(o: Record<string, any>, selector: MongoQuery<T>):
146145
ok = mongoWhere(o, innerSelector)
147146
}
148147
}
149-
} catch (e) {
148+
} catch (_e) {
150149
ok = false
151150
}
152151
}

packages/corelib/src/settings/objectWithOverrides.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import objectPath = require('object-path')
1+
import * as objectPath from 'object-path'
22
import { ReadonlyDeep } from 'type-fest'
33
import * as _ from 'underscore'
44
import { assertNever, clone, literal } from '../lib.js'

0 commit comments

Comments
 (0)