initPlugins parameters object
james-owen opened this issue · 2 comments
james-owen commented
Is your feature request related to a problem? Please describe.
When initializing plugins, occasionally several arguments are needed, which makes for too many arguments being passed to a single function.
Describe the solution you'd like
The function initPlugins in plugins.js
should pass an object to each plugin.
Current:
plugin(router, pluginDBAdapter, publish, sites)
Suggested:
plugin(router, paramsObject)
james-owen commented
Pull request to add a 5th parameter to this function #655
james-owen commented
@pedroalbr Considering getting the params
object started now, while we're working with plugins and potentially adding more params. The params would look like this:
plugin(router, pluginDBAdapter, publish, sites, paramsObj)
instead of the current:
plugin(router, pluginDBAdapter, publish, sites, site, [additional params])