Basically, when I sign in I can see the right records. If I log out and log in with a different user I still see the old records. I need to refresh the browser before I see the right data.
How can I refresh the subscription so it grabs the right records seamlessly?
@sergiotapia, although @shock is right, I think he missed an important point.
What you are doing wrong is that you never stop the previous subscription. When you call Meteor.subscribe, it adds a new subscription to the older one. As @shock said, you should either:
call handle.stop() on the previous subscription before calling subscribe again, or
call subscribe from an autorun
But, those solutions are not necessary, because Meteor has an automatic publish mechanism when user logs in/out. See [here][1] (second line). The optimal code is probably something like this, and nothing more: