navigateAction from the route does not update URLs
DaryaTarasowa opened this issue · 1 comments
DaryaTarasowa commented
Expected behavior
If I call the navigateAction from inside the route action, the URL changes to the new one
Actual behavior
Even though the actions from a route to which I redirect finish successflully, the url stays the same
Information about the Issue
deck: {
path: '/deck/:id(\\d+|\\d+-\\d+)/:stype?/:sid?/:spath?/:mode?/:theme?',
method: 'get',
page: 'deck',
handler: require('../components/Deck/Deck'),
action: (context, payload, done) => {
async.series([
(callback) => {
context.executeAction(loadDeck, payload, callback);
},
(callback) => {
context.executeAction(loadPresentation, payload, callback);
}
],
(err) => {
if(err) console.log(err);
done();
});
}
},
legacydeck: {
path: '/deck/:oldid(\\d+_\\w+.*)',
method: 'get',
action: (context, payload, done) => {
context.executeAction(loadLegacy, payload, (err, result) => {
if (err) console.log(err);
context.executeAction(navigateAction, {'method' : 'get', 'routeName': 'deck', 'params':{'id' :result}}, (err) => {
if (err) console.log(err);
done();
});
});
}
},
DaryaTarasowa commented
Found the solution here