mirror of
https://github.com/seejohnrun/haste-server.git
synced 2024-11-01 11:31:22 +00:00
30 lines
428 B
JavaScript
30 lines
428 B
JavaScript
|
|
/**
|
|
* Module dependencies.
|
|
*/
|
|
|
|
var Runnable = require('./runnable');
|
|
|
|
/**
|
|
* Expose `Hook`.
|
|
*/
|
|
|
|
module.exports = Hook;
|
|
|
|
/**
|
|
* Initialize a new `Hook` with the given `title` and callback `fn`.
|
|
*
|
|
* @param {String} title
|
|
* @param {Function} fn
|
|
* @api private
|
|
*/
|
|
|
|
function Hook(title, fn) {
|
|
Runnable.call(this, title, fn);
|
|
}
|
|
|
|
/**
|
|
* Inherit from `Runnable.prototype`.
|
|
*/
|
|
|
|
Hook.prototype.__proto__ = Runnable.prototype;
|