fastify / fastify-plugin

Plugin helper for Fastify
MIT License
197 stars 42 forks source link

docs: rename next callback to done to make consistent with core #210

Closed 58bits closed 1 year ago

58bits commented 1 year ago

This was done rather quickly, and so feel free to ignore if this is not at all correct.

While reading the core Fastify docs for Plugins - https://www.fastify.io/docs/latest/Reference/Plugins/ - the synchronous examples use the 'done callback, while the fastify-plugin docs use the next callback, and so the suggestion here is that the examples for the fastify-plugin completion callback be renamed to done to be consistent with core.

Again, no worries - if this is neither appropriate nor correct.