/** * Gets an idea by its slug without additional metas or terms * * @package WP Idea Stream * @subpackage ideas/functions * * @since 2.0.0 * * @param string $name the post_name of the idea to get * @uses WP_Idea_Stream_Idea::get_idea_by_name() to get the idea * @uses apply_filters() call 'wp_idea_stream_ideas_get_idea_by_name' to override/edit the retrieved idea * @return WP_Post the idea object */ function wp_idea_stream_ideas_get_idea_by_name($name = '') { if (empty($name)) { return false; } $idea = WP_Idea_Stream_Idea::get_idea_by_name($name); /** * @param WP_Post $idea the idea object * @param string $name the post_name of the idea */ return apply_filters('wp_idea_stream_ideas_get_idea_by_name', $idea, $name); }