Improve goBackOnError method