Fix redirect on error
Merge pull request #27 from atlasapi/fix-redirect-on-error

Fix redirect on error