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

codemod is removing async from methods #521

Closed
gitKrystan opened this issue Mar 14, 2023 · 1 comment · Fixed by #524
Closed

codemod is removing async from methods #521

gitKrystan opened this issue Mar 14, 2023 · 1 comment · Fixed by #524

Comments

@gitKrystan
Copy link
Collaborator

Input:

export default Controller.extend({
  async save() {
    await this.something;
  },
});

Expected Output:

export default class MyController extends Controller {
  async save() {
    await this.something;
  }
}

Actual Output:

export default class MyController extends Controller {
  save() {
    await this.something;
  }
}
@gitKrystan
Copy link
Collaborator Author

Check generators also.

gitKrystan added a commit to gitKrystan/ember-native-class-codemod that referenced this issue Mar 15, 2023
gitKrystan added a commit to gitKrystan/ember-native-class-codemod that referenced this issue Mar 15, 2023
gitKrystan added a commit to gitKrystan/ember-native-class-codemod that referenced this issue Mar 15, 2023
gitKrystan added a commit to gitKrystan/ember-native-class-codemod that referenced this issue Mar 15, 2023
wycats added a commit that referenced this issue Apr 5, 2023
Retain async / generator behavior on class methods (Fixes #521)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant