mirror of
https://github.com/wekan/wekan.git
synced 2025-09-22 01:50:48 +02:00

Fixes: #5533
Fixes: #5548
Revert "Switch from kadira:flow-router to ostrio:flow-router-extra"
This reverts commit 718c1a393d
.
28 lines
615 B
JavaScript
28 lines
615 B
JavaScript
Route = function(router, pathDef, options) {
|
|
options = options || {};
|
|
this.options = options;
|
|
this.name = options.name;
|
|
this.pathDef = pathDef;
|
|
|
|
// Route.path is deprecated and will be removed in 3.0
|
|
this.path = pathDef;
|
|
|
|
this.action = options.action || Function.prototype;
|
|
this.subscriptions = options.subscriptions || Function.prototype;
|
|
this._subsMap = {};
|
|
};
|
|
|
|
|
|
Route.prototype.register = function(name, sub, options) {
|
|
this._subsMap[name] = sub;
|
|
};
|
|
|
|
|
|
Route.prototype.subscription = function(name) {
|
|
return this._subsMap[name];
|
|
};
|
|
|
|
|
|
Route.prototype.middleware = function(middleware) {
|
|
|
|
};
|