mirror of
https://github.com/Chocobozzz/PeerTube.git
synced 2025-10-04 02:09:37 +02:00
Don't call plugin register/unregister methods
This commit is contained in:
parent
257fa0d1a0
commit
841ddf8886
4 changed files with 34 additions and 13 deletions
|
@ -150,7 +150,7 @@ async function installPlugin (req: express.Request, res: express.Response) {
|
|||
: undefined
|
||||
|
||||
try {
|
||||
const plugin = await PluginManager.Instance.install(toInstall, pluginVersion, fromDisk)
|
||||
const plugin = await PluginManager.Instance.install({ toInstall, version: pluginVersion, fromDisk })
|
||||
|
||||
return res.json(plugin.toFormattedJSON())
|
||||
} catch (err) {
|
||||
|
@ -177,7 +177,7 @@ async function updatePlugin (req: express.Request, res: express.Response) {
|
|||
async function uninstallPlugin (req: express.Request, res: express.Response) {
|
||||
const body: ManagePlugin = req.body
|
||||
|
||||
await PluginManager.Instance.uninstall(body.npmName)
|
||||
await PluginManager.Instance.uninstall({ npmName: body.npmName })
|
||||
|
||||
return res.status(HttpStatusCode.NO_CONTENT_204).end()
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue