Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix wrong return type on flip and setFlashMode #234

Conversation

diesieben07
Copy link
Contributor

flip and setFlashMode are defined as returning void, which is not correct. These methods (like all others) return a Promise. The wrong return type makes it impossible to catch any errors from these methods without an unsafe cast (as unknown as Promise<void>)

@diesieben07 diesieben07 force-pushed the fix-missing-promise-return-type branch from 83c36fd to bd425ed Compare July 13, 2022 10:08
@pbowyer pbowyer merged commit 37b8d86 into capacitor-community:master Jul 20, 2022
@pbowyer
Copy link
Collaborator

pbowyer commented Jul 20, 2022

Thank you for your contribution! This is now merged and will be in the next release

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.

None yet

2 participants