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

Remove tryInvoke (from @ember/utils) calls #398

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

brunoocasali
Copy link

  • Remove tryInvoke calls from invoke helper and replace with javascript optional chaining.

Related to: https://emberjs.github.io/rfcs/0673-deprecate-tryinvoke.html

Copy link
Contributor

@bertdeblock bertdeblock left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

tryInvoke's last argument should be an array, but with the native approach we need to spread the args to achieve the same result. Atm the tests still pass by accident, but maybe this should also be tested more explicitly?

addon/helpers/invoke.js Outdated Show resolved Hide resolved
addon/helpers/invoke.js Outdated Show resolved Hide resolved
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.

2 participants