Search code examples
meteorflow-router

Flowrouter reset password route not rendering


I'm trying to setup the reset password route however there appears to be something wrong with the route and I'm not sure what it is.

email link

http://localhost:3000/reset-password/MKlpo8uJVAsZ5P_UnU1yUHi_4Ez2csh0DtEo4umazwU

Path: routes.js

    FlowRouter.route( '/reset-password/:token', {
  name: 'atResetPwd',
  action: function() {
    BlazeLayout.render('loginTemplates', {
      navbar: 'navbar',
      content: 'atResetPwd',
      footer: 'footer'
    });
  }
});

Solution

  • you are not passing the token to your route, so it's not available to your functions.

        FlowRouter.route( '/reset-password/:token', {
      name: 'atResetPwd',
      action: function(params) {
        BlazeLayout.render('loginTemplates', {
          navbar: 'navbar',
          content: 'atResetPwd',
          footer: 'footer'
        });
      }
    });
    

    Then you can try to retrieve the token from your client side code, to call the appropriate method.