| Conditions | 2 |
| Paths | 2 |
| Total Lines | 14 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 24 | public function has_value( $language ) { |
||
| 25 | if ( ! isset( $this->arr[ $language ] ) ) { |
||
| 26 | $cache = MslsSqlCacher::init( __CLASS__ )->set_params( $this->args ); |
||
| 27 | |||
| 28 | $this->arr[ $language ] = $cache->get_var( |
||
| 29 | $cache->prepare( |
||
| 30 | "SELECT count(ID) FROM {$cache->posts} WHERE YEAR(post_date) = %d AND post_status = 'publish'", |
||
| 31 | $this->get_arg( 0, 0 ) |
||
| 32 | ) |
||
| 33 | ); |
||
| 34 | } |
||
| 35 | |||
| 36 | return (bool) $this->arr[ $language ]; |
||
| 37 | } |
||
| 38 | |||
| 49 |