Skip to content

Commit

Permalink
Fix syntax error in node 10
Browse files Browse the repository at this point in the history
  • Loading branch information
zodern committed Oct 7, 2024
1 parent 36f139d commit e7df2cf
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/plugin-api.js
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,7 @@ export default class PluginAPI {
process.exit(1);
}
}
_runHooks = async function(handlers, hookName) {
async _runHooks(handlers, hookName) {
const messagePrefix = `> Running hook ${hookName}`;

for (const hookHandler of handlers) {
Expand All @@ -270,7 +270,7 @@ export default class PluginAPI {
}
}
}
_runPreHooks = async function(name) {
async _runPreHooks(name) {
const hookName = `pre.${name}`;

if (this.program['show-hook-names']) {
Expand All @@ -282,8 +282,8 @@ export default class PluginAPI {

await this._runHooks(hookList, name);
}
};
_runPostHooks = async function(commandName) {
}
async _runPostHooks(commandName) {
const hookName = `post.${commandName}`;

if (this.program['show-hook-names']) {
Expand All @@ -295,7 +295,7 @@ export default class PluginAPI {

await this._runHooks(hookList, hookName);
}
};
}
_commandErrorHandler(e) {
log('_commandErrorHandler');
process.exitCode = 1;
Expand All @@ -313,7 +313,7 @@ export default class PluginAPI {

process.exit(1);
}
runCommand = async function(name) {
async runCommand(name) {
const firstCommand = this.commandHistory.length === 0;

if (!name) {
Expand Down

0 comments on commit e7df2cf

Please sign in to comment.