Skip to content

Conversation

@ac-mmi
Copy link

@ac-mmi ac-mmi commented Feb 15, 2025

In file _basehook.js here in this line const invocationResult = this.context.invokeMethod(this.key, client, argsCount they weren't
handling async results properly—if a hook returned a promise. Now, I added a check: if result is a promise, it then() waits for it and catches any errors. If it’s not a promise, it works the same way as before.

Fixes #4379

@ac-mmi ac-mmi closed this Feb 15, 2025
@ac-mmi ac-mmi reopened this Feb 16, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

before hook does not run with async callback returning Promise<undefined>.

1 participant