Catch exception for AttributeError

A an error with be thrown if page does not have a next page url