Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

Fix issue: 15536 #15542

Closed
wants to merge 1 commit into from
Closed

Fix issue: 15536 #15542

wants to merge 1 commit into from

Conversation

mhevery
Copy link
Contributor

@mhevery mhevery commented Dec 22, 2016

This PR only demonstrates a fix, it still needs for someone to add tests.

Closes #15536

@@ -100,7 +100,7 @@ function annotate(fn, strictDi, name) {
last;

if (typeof fn === 'function') {
if (!($inject = fn.$inject)) {
if (!($inject = fn.hasOwnProperty('$inject'))) {
Copy link
Member

Choose a reason for hiding this comment

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

@gkalpak
Copy link
Member

gkalpak commented Dec 22, 2016

Duplicate of #15538 (afaict).
(In case I missed the point please reopen.)

@gkalpak gkalpak closed this Dec 22, 2016
@matsko matsko deleted the mhevery-issue-15536 branch January 11, 2017 17:22
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

$inject with ES6 classes can inject the wrong dependencies
3 participants