Instead of having multiple definitions of the this count method, we could have 1 function to summarise url state and pass it the state as a parameter. This would reduce reuse of code and reduce the number of lines of code