Bug fix for temp WP bug fix on 404 pages

Signed-off-by: Phil Johnston <johnstonphilip@gmail.com>