| @@ -17,13 +17,8 @@ | ||
| 17 | 17 | */ |
| 18 | 18 | class Api { |
| 19 | 19 | |
| 20 | 20 | /** |
| 21 | - * Elementor library option key. | |
| 22 | - */ | |
| 23 | - const LIBRARY_OPTION_KEY = 'elementor_remote_info_library'; | |
| 24 | - | |
| 25 | - /** | |
| 26 | 21 | * Elementor feed option key. |
| 27 | 22 | */ |
| 28 | 23 | const FEED_OPTION_KEY = 'elementor_remote_info_feed_data'; |
| 29 | 24 | |
| @@ -223,24 +218,9 @@ | ||
| 223 | 218 | } |
| 224 | 219 | |
| 225 | 220 | $library_data = json_decode( wp_remote_retrieve_body( $response ), true ); |
| 226 | 221 | |
| 227 | - /** | |
| 228 | - * Filters the library data to allow 3rd party extending the response data. | |
| 229 | - * | |
| 230 | - * @since 3.32.2 | |
| 231 | - * @param-out array $library_data an array of templates data. | |
| 232 | - */ | |
| 233 | - $library_data = apply_filters( 'elementor/remote/library/data', $library_data ); | |
| 234 | - | |
| 235 | - if ( empty( $library_data ) || ! is_array( $library_data ) ) { | |
| 236 | - return []; | |
| 237 | - } | |
| 238 | - | |
| 239 | - // the following update & get are a temporary measure, to allow 3rd party plugins inject more templates: | |
| 240 | - update_option( self::LIBRARY_OPTION_KEY, $library_data, 'no' ); | |
| 241 | - | |
| 242 | - return get_option( self::LIBRARY_OPTION_KEY, $library_data ); | |
| 222 | + return empty( $library_data ) ? [] : $library_data; | |
| 243 | 223 | } |
| 244 | 224 | |
| 245 | 225 | /** |
| 246 | 226 | * Get feed data. |