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

advice order is wrong when on stacked joinpoints [breaking changes] #116

Closed
k1r0s opened this issue Aug 22, 2018 · 0 comments · Fixed by #117
Closed

advice order is wrong when on stacked joinpoints [breaking changes] #116

k1r0s opened this issue Aug 22, 2018 · 0 comments · Fixed by #117
Labels

Comments

@k1r0s
Copy link
Owner

k1r0s commented Aug 22, 2018

class Foo {

  @beforeMethod(() => console.log("Fucked"))
  @beforeMethod(() => console.log("Pretty"))
  @beforeMethod(() => console.log("Im"))
  static do0(stuff) {
    return stuff
  }
}

this should print "Fucked Pretty Im" but I does reverse ways

(tests are wrong)

In fact this is intended to be equal order

  @beforeMethod(() => console.log("Im"))
  @beforeMethod(() => console.log("Pretty"))
  @beforeMethod(() => console.log("Fucked"))
  // or 
  @beforeMethod(() => console.log("Im"), () => console.log("Pretty"), () => console.log("Fucked"))

but its just the oposite

@k1r0s k1r0s added the bug label Aug 22, 2018
k1r0s added a commit that referenced this issue Aug 22, 2018
BREAKING CHANGE: stacked joinpoints will be executed from top to bottom, see iss-116

fix #116
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant