re-adding get_redirect_query method