converting Redhook to WP