Fix plugin register when Prosody enabled but not installed

This commit is contained in:
John Livingston 2021-09-14 16:49:11 +02:00
parent 6cdf44e92a
commit 543e454b51
No known key found for this signature in database
GPG Key ID: B17B5640CE66CDBC
2 changed files with 7 additions and 2 deletions

View File

@ -1,10 +1,11 @@
# Changelog # Changelog
## ??? ## v4.0.1
### Minor changes and fixes ### Minor changes and fixes
* NPM dependencies update * NPM dependencies update
* Fix plugin register when Prosody enabled but not installed
## v4.0.0 ## v4.0.0

View File

@ -23,7 +23,11 @@ async function register (options: RegisterServerOptions): Promise<any> {
await initCustomFields(options) await initCustomFields(options)
await initRouters(options) await initRouters(options)
try {
await ensureProsodyRunning(options) await ensureProsodyRunning(options)
} catch (error) {
options.peertubeHelpers.logger('Error when launching Prosody: ' + (error as string))
}
} }
async function unregister (): Promise<any> { async function unregister (): Promise<any> {