From 690bb8f9f3413147a4f71d5ff0a3cd8170a94ce3 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Wed, 17 Aug 2022 15:36:03 +0200 Subject: Prefer using Object.values --- server/tools/peertube-redundancy.ts | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'server/tools') diff --git a/server/tools/peertube-redundancy.ts b/server/tools/peertube-redundancy.ts index 2c62a3c19..4bb9fbc5a 100644 --- a/server/tools/peertube-redundancy.ts +++ b/server/tools/peertube-redundancy.ts @@ -1,13 +1,12 @@ import CliTable3 from 'cli-table3' import { Command, program } from 'commander' -import { uniq } from 'lodash' import { URL } from 'url' import validator from 'validator' +import { uniqify } from '@shared/core-utils' import { HttpStatusCode, VideoRedundanciesTarget } from '@shared/models' import { assignToken, buildServer, getServerCredentials } from './cli' import bytes = require('bytes') - program .name('redundancy') .usage('[command] [options]') @@ -77,7 +76,7 @@ async function listRedundanciesCLI (target: VideoRedundanciesTarget) { totalSize = bytes(tmp) } - const instances = uniq( + const instances = uniqify( webtorrentFiles.concat(streamingPlaylists) .map(r => r.fileUrl) .map(u => new URL(u).host) -- cgit v1.2.3