wekan/packages/kadira-flow-router/lib/router.js
Lauri Ojansivu 73e265d8fd Include to Wekan packages directory contents, so that meteor command would build all directly.
This also simplifies build scripts.

Thanks to xet7 !
2019-04-20 15:18:33 +03:00

9 lines
462 B
JavaScript

Router.prototype.url = function() {
// We need to remove the leading base path, or "/", as it will be inserted
// automatically by `Meteor.absoluteUrl` as documented in:
// http://docs.meteor.com/#/full/meteor_absoluteurl
var completePath = this.path.apply(this, arguments);
var basePath = this._basePath || '/';
var pathWithoutBase = completePath.replace(new RegExp('^' + basePath + '\/|(\/)'), '');
return Meteor.absoluteUrl(pathWithoutBase);
};