only establish the redirect if the post is published