1 | <?php |
||
3 | class ClassyQueryHelper { |
||
|
|||
4 | |||
5 | /** |
||
6 | * Finds or creates new query based on provided params |
||
7 | * |
||
8 | * @param array/boolean $args |
||
9 | * @return object WP_Query |
||
10 | */ |
||
11 | public static function find_query($args = false) { |
||
31 | |||
32 | /** |
||
33 | * Returns current WP_Query |
||
34 | * |
||
35 | * @return object WP_Query |
||
36 | */ |
||
37 | public static function get_current_query() { |
||
48 | |||
49 | /** |
||
50 | * Checks and returns WP_Query for home posts page |
||
51 | * |
||
52 | * @param object $query WP_Query |
||
53 | * @return object WP_Query |
||
54 | */ |
||
55 | private static function handle_maybe_custom_posts_page( $query ) { |
||
70 | |||
71 | } |
You can fix this by adding a namespace to your class:
When choosing a vendor namespace, try to pick something that is not too generic to avoid conflicts with other libraries.