| @@ -1,7 +1,7 @@ | ||
| 1 | 1 | <?php |
| 2 | 2 | /** |
| 3 | - * Templates plugin functions | |
| 3 | + * Templates plugin functions. | |
| 4 | 4 | * |
| 5 | 5 | * @package sharing-image |
| 6 | 6 | * @author Anton Lukin |
| 7 | 7 | */ |
| @@ -18,9 +18,9 @@ | ||
| 18 | 18 | * @param string $object_type Optional. Requested meta type, can be singular or taxonomy. |
| 19 | 19 | * Default is determined by the type of the template in which it is called. |
| 20 | 20 | */ |
| 21 | 21 | function sharing_image_poster( $object_id = null, $object_type = null ) { |
| 22 | - return ( new Sharing_Image\Meta() )->get_poster( $object_id, $object_type ); | |
| 22 | + return Sharing_Image\Meta::get_poster( $object_id, $object_type ); | |
| 23 | 23 | } |
| 24 | 24 | } |
| 25 | 25 | |
| 26 | 26 | if ( ! function_exists( 'sharing_image_poster_src' ) ) { |
| @@ -32,7 +32,7 @@ | ||
| 32 | 32 | * @param string $object_type Optional. Requested meta type, can be singular or taxonomy. |
| 33 | 33 | * Default is determined by the type of the template in which it is called. |
| 34 | 34 | */ |
| 35 | 35 | function sharing_image_poster_src( $object_id = null, $object_type = null ) { |
| 36 | - return ( new Sharing_Image\Meta() )->get_poster_src( $object_id, $object_type ); | |
| 36 | + return Sharing_Image\Meta::get_poster_src( $object_id, $object_type ); | |
| 37 | 37 | } |
| 38 | 38 | } |