Fix linter issues

This commit is contained in:
freearhey 2025-04-29 00:28:42 +03:00
parent a28122809a
commit dac7d19f40
13 changed files with 15 additions and 16 deletions

View file

@ -1,4 +1,4 @@
import { CSV, IssueLoader, CSVParser, Issue, IssueData } from '../../core'
import { CSV, IssueLoader, Issue, IssueData } from '../../core'
import { createChannelId, createFeedId } from '../../utils'
import { Channel, Feed, BlocklistRecord } from '../../models'
import { Storage, Collection, Logger } from '@freearhey/core'
@ -11,7 +11,6 @@ const dataStorage = new Storage(DATA_DIR)
const logger = new Logger({ level: -999 })
async function main() {
const parser = new CSVParser()
const issueLoader = new IssueLoader()
const dataLoader = new DataLoader({ storage: dataStorage })
@ -101,7 +100,7 @@ async function editFeeds(issues: Collection, data: DataLoaderData) {
)
if (!found) return
let channelId: string | undefined = found.channelId
const channelId: string | undefined = found.channelId
let feedId: string | undefined = found.id
if (issueData.has('feed_name')) {
const name = issueData.getString('feed_name') || found.name

View file

@ -238,7 +238,7 @@ function findDuplicatesBy(items: Collection, keys: string[]) {
const duplicates = new Collection()
const buffer = new Dictionary()
items.forEach((item, i = 0) => {
items.forEach((item: { [key: string]: string | number }) => {
const normId = keys.map(key => item[key].toString().toLowerCase()).join()
if (buffer.has(normId)) {
duplicates.add(item)