aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/lib
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2022-11-14 14:49:50 +0100
committerChocobozzz <me@florianbigard.com>2022-11-14 16:21:59 +0100
commitff91b644fb1b063d0a8eff7492beb1a9bf7e4ce1 (patch)
tree31fc991c12ce66e0bcd59a3bc3cd563c15b24690 /server/lib
parenta742347d50234793fceb08034c20e6881a65d544 (diff)
downloadPeerTube-ff91b644fb1b063d0a8eff7492beb1a9bf7e4ce1.tar.gz
PeerTube-ff91b644fb1b063d0a8eff7492beb1a9bf7e4ce1.tar.zst
PeerTube-ff91b644fb1b063d0a8eff7492beb1a9bf7e4ce1.zip
Add ability to install alpha/beta/rc plugin
Diffstat (limited to 'server/lib')
-rw-r--r--server/lib/plugins/yarn.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/server/lib/plugins/yarn.ts b/server/lib/plugins/yarn.ts
index d105b95e0..9cf6ec9e9 100644
--- a/server/lib/plugins/yarn.ts
+++ b/server/lib/plugins/yarn.ts
@@ -1,7 +1,7 @@
1import { outputJSON, pathExists } from 'fs-extra' 1import { outputJSON, pathExists } from 'fs-extra'
2import { join } from 'path' 2import { join } from 'path'
3import { execShell } from '../../helpers/core-utils' 3import { execShell } from '../../helpers/core-utils'
4import { isNpmPluginNameValid, isPluginVersionValid } from '../../helpers/custom-validators/plugins' 4import { isNpmPluginNameValid, isPluginStableOrUnstableVersionValid } from '../../helpers/custom-validators/plugins'
5import { logger } from '../../helpers/logger' 5import { logger } from '../../helpers/logger'
6import { CONFIG } from '../../initializers/config' 6import { CONFIG } from '../../initializers/config'
7import { getLatestPluginVersion } from './plugin-index' 7import { getLatestPluginVersion } from './plugin-index'
@@ -69,5 +69,5 @@ function checkNpmPluginNameOrThrow (name: string) {
69} 69}
70 70
71function checkPluginVersionOrThrow (name: string) { 71function checkPluginVersionOrThrow (name: string) {
72 if (!isPluginVersionValid(name)) throw new Error('Invalid NPM plugin version to install') 72 if (!isPluginStableOrUnstableVersionValid(name)) throw new Error('Invalid NPM plugin version to install')
73} 73}