Skip to content

Commit

Permalink
🐛 Fix: pluginHandler args length error
Browse files Browse the repository at this point in the history
  • Loading branch information
Molunerfinn committed Dec 26, 2019
1 parent 50467c7 commit e15eac2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/lib/PluginHandler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ class PluginHandler {
this.ctx = ctx
}

async install (plugins: string[], proxy: string = '', env: ProcessEnv): Promise<void> {
async install (plugins: string[], proxy: string = '', env?: ProcessEnv): Promise<void> {
plugins = plugins.map((item: string) => 'picgo-plugin-' + item)
const result = await this.execCommand('install', plugins, this.ctx.baseDir, proxy, env)
if (!result.code) {
Expand Down Expand Up @@ -51,7 +51,7 @@ class PluginHandler {
})
}
}
async update (plugins: string[], proxy: string = '', env: ProcessEnv): Promise<void> {
async update (plugins: string[], proxy: string = '', env?: ProcessEnv): Promise<void> {
plugins = plugins.map((item: string) => 'picgo-plugin-' + item)
const result = await this.execCommand('update', plugins, this.ctx.baseDir, proxy, env)
if (!result.code) {
Expand Down

0 comments on commit e15eac2

Please sign in to comment.