feathersjs / feathers

The API and real-time application framework
https://feathersjs.com
MIT License
14.97k stars 742 forks source link

fix(schema): Allow regular functions in resolvers #3487

Closed ramijarrar closed 1 month ago

ramijarrar commented 1 month ago

Alters the expected return type of property resolvers and converters from Promise<T> to Promise<T> | T.

This ensures users are not forced to unnecessarily provide async functions with no await expression, which is often considered bad practice and disallowed by linting rules.

daffl commented 1 month ago

This is a really good change. Will go out with the next release!