Skip to content

prefer-await-to-then should flag promise.catch/finally as well #187

Open
@jp7837

Description

@jp7837

Description

For consistency, I feel that the prefer-await-to-then rule should also flag promise.catch and promise.finally so we can enforce async/await everywhere if desired.

Steps to Reproduce

  1. Run prefer-await-to-then on code with a Promise.prototype.catch invocation

Expected behavior: catch call is flagged

Actual behavior: rule does not report a problem

Versions

[Please fill this in if you are submitting a bug report]

  • Node version: 12.16.1
  • ESLint version: 6.7.2
  • eslint-plugin-promise version: 4.2.1

Additional Information

None, suggestion

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions