convert link.href to string

When I used this code with Google Appengine it didn't work because the redirect_url was 'unicode'. I propose a really simple change : convert the redirect_url to a string