Kadira Flow-router: onpopstate state undefined

I’ve encountered an issue while working with the Kadira Flow-Router package.
For some reason in one specific route when I try to go back using the default back button of the browser the redirection code breaks.
For example, if I’m in /esports and then go to /esports/team, when trying to go back to /esports the onpopstate method gets the e.state object empty, breaking the redirection, this is strange because in other routes it works fine and it’s using the same code.
Does anyone have an idea of what is happening? Thank you!
Error message in the browser console:

Code of the Esports route: