Merge pull request #578 from therebelrobot/bugfix/m.route-redirect-url-update

Added check for this.attrs into m.route
This commit is contained in:
Leo Horie 2015-04-22 20:21:43 -04:00
commit b0c4482ecc
2 changed files with 3 additions and 3 deletions

View file

@ -615,7 +615,7 @@ var m = (function app(window, undefined) {
var element = arguments[0];
var isInitialized = arguments[1];
var context = arguments[2];
element.href = (m.route.mode !== 'pathname' ? $location.pathname : '') + modes[m.route.mode] + this.attrs.href;
element.href = (m.route.mode !== 'pathname' ? $location.pathname : '') + modes[m.route.mode] + (this.attrs ? this.attrs.href : '');
if (element.addEventListener) {
element.removeEventListener("click", routeUnobtrusive);
element.addEventListener("click", routeUnobtrusive)

4
mithril.min.js vendored

File diff suppressed because one or more lines are too long