Closed nicolashery closed 10 years ago
Given this code:
var Handler = { index: function(req) { console.log(req); } }; Aviator.pushStateEnabled = false; Aviator.setRoutes({ '/users': { target: Handler, '/': 'index' }, '/cats/:id': { target: Handler, '/': 'index' } }); Aviator.dispatch(); Aviator.navigate('/users?foo=bar');
I get a Uncaught TypeError: Cannot read property 'indexOf' of undefined (aviator.js:898).
Uncaught TypeError: Cannot read property 'indexOf' of undefined (aviator.js:898)
But if I comment out the pushStateEnabled = false, it works as expected.
pushStateEnabled = false
I think i have an idea of whats going on here. Should have a fix shortly
Given this code:
I get a
Uncaught TypeError: Cannot read property 'indexOf' of undefined (aviator.js:898)
.But if I comment out the
pushStateEnabled = false
, it works as expected.