Update urlrewrite_redirect.py

not log in = redirect
logged in = not redirect
we need to check the headers logged in.
Merge pull request #381 from blastcodem/patch-2

Update urlrewrite_redirect.py