only redirect for 3xx status codes
Merge pull request #1120 from andrerod/release-0.7.5

only redirect for 3xx status codes