Fix bug with callback

Oops, one last PR! Looks like the callback fix broke it with certain redirects. Sorry about that, fixed here...