The eslint-plugin-promise(catch-or-return) isn't properly detecting a return with inline arrow functions.
This is the error that its reporting, however looking at the snippet, the error is invalid since the promise is being returned.
I'm using 1.35.0
× eslint-plugin-promise(catch-or-return): Expected `catch` or `return`.
╭─[src/areas/project-management/modals/template-task-modal/template-task-form-handlers.tsx:42:30]
41 │ uploadImage: () => Promise.resolve(undefined),
42 │ openLinkModalPrompt: () => Promise.resolve(null),
· ─────────────────────
43 │ submitTemplate: () => Promise.resolve({ id: '' }),
╰────
help: Return the promise or chain a `catch()`.
The
eslint-plugin-promise(catch-or-return)isn't properly detecting a return with inline arrow functions.This is the error that its reporting, however looking at the snippet, the error is invalid since the promise is being returned.
I'm using
1.35.0