mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-10-28 17:46:16 +01:00
moved comments above method
This commit is contained in:
@@ -5,6 +5,12 @@ var winston = require('winston'),
|
||||
|
||||
module.exports = function(Plugins) {
|
||||
|
||||
/*
|
||||
`data` is an object consisting of (* is required):
|
||||
`data.hook`*, the name of the NodeBB hook
|
||||
`data.method`*, the method called in that plugin
|
||||
`data.priority`, the relative priority of the method when it is eventually called (default: 10)
|
||||
*/
|
||||
Plugins.registerHook = function(id, data, callback) {
|
||||
function register() {
|
||||
Plugins.loadedHooks[data.hook] = Plugins.loadedHooks[data.hook] || [];
|
||||
@@ -14,12 +20,6 @@ module.exports = function(Plugins) {
|
||||
callback();
|
||||
}
|
||||
}
|
||||
/*
|
||||
`data` is an object consisting of (* is required):
|
||||
`data.hook`*, the name of the NodeBB hook
|
||||
`data.method`*, the method called in that plugin
|
||||
`data.priority`, the relative priority of the method when it is eventually called (default: 10)
|
||||
*/
|
||||
|
||||
var method;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user