Tidied up threading for WP