mirror of
https://github.com/iptv-org/iptv
synced 2025-12-16 10:26:48 -05:00
Fixes linter issues
This commit is contained in:
@@ -78,7 +78,7 @@ export class DataProcessor {
|
|||||||
const feedsGroupedByChannelId = feeds.groupBy((feed: Feed) => feed.channelId)
|
const feedsGroupedByChannelId = feeds.groupBy((feed: Feed) => feed.channelId)
|
||||||
const feedsGroupedById = feeds.groupBy((feed: Feed) => feed.id)
|
const feedsGroupedById = feeds.groupBy((feed: Feed) => feed.id)
|
||||||
|
|
||||||
let logos = new Collection(data.logos).map(data => new Logo(data).withFeed(feedsGroupedById))
|
const logos = new Collection(data.logos).map(data => new Logo(data).withFeed(feedsGroupedById))
|
||||||
const logosGroupedByChannelId = logos.groupBy((logo: Logo) => logo.channelId)
|
const logosGroupedByChannelId = logos.groupBy((logo: Logo) => logo.channelId)
|
||||||
const logosGroupedByStreamId = logos.groupBy((logo: Logo) => logo.getStreamId())
|
const logosGroupedByStreamId = logos.groupBy((logo: Logo) => logo.getStreamId())
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
import { Country, Subdivision, Stream, Playlist } from '../models'
|
import { Country, Stream, Playlist } from '../models'
|
||||||
import { Collection, Storage, File } from '@freearhey/core'
|
import { Collection, Storage, File } from '@freearhey/core'
|
||||||
import { PUBLIC_DIR } from '../constants'
|
import { PUBLIC_DIR } from '../constants'
|
||||||
import { Generator } from './generator'
|
import { Generator } from './generator'
|
||||||
|
|||||||
@@ -23,7 +23,7 @@ export class RawGenerator implements Generator {
|
|||||||
async generate() {
|
async generate() {
|
||||||
const files = this.streams.groupBy((stream: Stream) => stream.getFilename())
|
const files = this.streams.groupBy((stream: Stream) => stream.getFilename())
|
||||||
|
|
||||||
for (let filename of files.keys()) {
|
for (const filename of files.keys()) {
|
||||||
const streams = new Collection(files.get(filename)).map((stream: Stream) => {
|
const streams = new Collection(files.get(filename)).map((stream: Stream) => {
|
||||||
const groupTitle = stream.getCategoryNames().join(';')
|
const groupTitle = stream.getCategoryNames().join(';')
|
||||||
if (groupTitle) stream.groupTitle = groupTitle
|
if (groupTitle) stream.groupTitle = groupTitle
|
||||||
|
|||||||
@@ -23,7 +23,7 @@ export class SourcesGenerator implements Generator {
|
|||||||
async generate() {
|
async generate() {
|
||||||
const files: Dictionary = this.streams.groupBy((stream: Stream) => stream.getFilename())
|
const files: Dictionary = this.streams.groupBy((stream: Stream) => stream.getFilename())
|
||||||
|
|
||||||
for (let filename of files.keys()) {
|
for (const filename of files.keys()) {
|
||||||
if (!filename) continue
|
if (!filename) continue
|
||||||
|
|
||||||
let streams = new Collection(files.get(filename))
|
let streams = new Collection(files.get(filename))
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
import { Country, Subdivision, Stream, Playlist } from '../models'
|
import { Subdivision, Stream, Playlist } from '../models'
|
||||||
import { Collection, Storage, File } from '@freearhey/core'
|
import { Collection, Storage, File } from '@freearhey/core'
|
||||||
import { PUBLIC_DIR } from '../constants'
|
import { PUBLIC_DIR } from '../constants'
|
||||||
import { Generator } from './generator'
|
import { Generator } from './generator'
|
||||||
|
|||||||
@@ -35,7 +35,7 @@ export class Stream {
|
|||||||
this.id = id || undefined
|
this.id = id || undefined
|
||||||
this.channelId = data.channelId || undefined
|
this.channelId = data.channelId || undefined
|
||||||
this.feedId = data.feedId || undefined
|
this.feedId = data.feedId || undefined
|
||||||
this.title = data.title || undefined
|
this.title = data.title || ''
|
||||||
this.url = data.url
|
this.url = data.url
|
||||||
this.referrer = data.referrer || undefined
|
this.referrer = data.referrer || undefined
|
||||||
this.userAgent = data.userAgent || undefined
|
this.userAgent = data.userAgent || undefined
|
||||||
@@ -81,7 +81,7 @@ export class Stream {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function parseDirectives(string: string) {
|
function parseDirectives(string: string) {
|
||||||
let directives = new Collection()
|
const directives = new Collection()
|
||||||
|
|
||||||
if (!string) return directives
|
if (!string) return directives
|
||||||
|
|
||||||
|
|||||||
@@ -33,9 +33,9 @@ export class SubdivisionTable implements Table {
|
|||||||
|
|
||||||
if (!parsedCountrySubdivisions.length) return
|
if (!parsedCountrySubdivisions.length) return
|
||||||
|
|
||||||
output += `\r\n<details>\r\n\<summary>${country.name}</summary>\r\n`
|
output += `\r\n<details>\r\n<summary>${country.name}</summary>\r\n`
|
||||||
|
|
||||||
let data = new Collection()
|
const data = new Collection()
|
||||||
|
|
||||||
parsedCountrySubdivisions.forEach((logItem: LogItem) => {
|
parsedCountrySubdivisions.forEach((logItem: LogItem) => {
|
||||||
const file = new File(logItem.filepath)
|
const file = new File(logItem.filepath)
|
||||||
|
|||||||
Reference in New Issue
Block a user