Completed
Push — develop ( 130e0b...3fce1e )
by David
02:58
created
src/wordlift.php 2 patches
Indentation   +233 added lines, -233 removed lines patch added patch discarded remove patch
@@ -49,7 +49,7 @@  discard block
 block discarded – undo
49 49
 
50 50
 // If this file is called directly, abort.
51 51
 if ( ! defined( 'WPINC' ) ) {
52
-	die;
52
+    die;
53 53
 }
54 54
 
55 55
 require_once plugin_dir_path( __FILE__ ) . 'vendor/autoload.php';
@@ -72,7 +72,7 @@  discard block
 block discarded – undo
72 72
  */
73 73
 function wl_write_log( $log ) {
74 74
 
75
-	Wordlift_Log_Service::get_instance()->debug( $log );
75
+    Wordlift_Log_Service::get_instance()->debug( $log );
76 76
 
77 77
 }
78 78
 
@@ -89,7 +89,7 @@  discard block
 block discarded – undo
89 89
  */
90 90
 function wl_write_log_hide_key( $text ) {
91 91
 
92
-	return str_ireplace( wl_configuration_get_key(), '<hidden>', $text );
92
+    return str_ireplace( wl_configuration_get_key(), '<hidden>', $text );
93 93
 }
94 94
 
95 95
 /**
@@ -97,21 +97,21 @@  discard block
 block discarded – undo
97 97
  * see http://vip.wordpress.com/documentation/register-additional-html-attributes-for-tinymce-and-wp-kses/
98 98
  */
99 99
 function wordlift_allowed_post_tags() {
100
-	global $allowedposttags;
101
-
102
-	$tags           = array( 'span' );
103
-	$new_attributes = array(
104
-		'itemscope' => array(),
105
-		'itemtype'  => array(),
106
-		'itemprop'  => array(),
107
-		'itemid'    => array(),
108
-	);
109
-
110
-	foreach ( $tags as $tag ) {
111
-		if ( isset( $allowedposttags[ $tag ] ) && is_array( $allowedposttags[ $tag ] ) ) {
112
-			$allowedposttags[ $tag ] = array_merge( $allowedposttags[ $tag ], $new_attributes );
113
-		}
114
-	}
100
+    global $allowedposttags;
101
+
102
+    $tags           = array( 'span' );
103
+    $new_attributes = array(
104
+        'itemscope' => array(),
105
+        'itemtype'  => array(),
106
+        'itemprop'  => array(),
107
+        'itemid'    => array(),
108
+    );
109
+
110
+    foreach ( $tags as $tag ) {
111
+        if ( isset( $allowedposttags[ $tag ] ) && is_array( $allowedposttags[ $tag ] ) ) {
112
+            $allowedposttags[ $tag ] = array_merge( $allowedposttags[ $tag ], $new_attributes );
113
+        }
114
+    }
115 115
 }
116 116
 
117 117
 // add allowed post tags.
@@ -122,18 +122,18 @@  discard block
 block discarded – undo
122 122
  */
123 123
 function wordlift_admin_enqueue_scripts() {
124 124
 
125
-	// Added for compatibility with WordPress 3.9 (see http://make.wordpress.org/core/2014/04/16/jquery-ui-and-wpdialogs-in-wordpress-3-9/)
126
-	wp_enqueue_script( 'wpdialogs' );
127
-	wp_enqueue_style( 'wp-jquery-ui-dialog' );
125
+    // Added for compatibility with WordPress 3.9 (see http://make.wordpress.org/core/2014/04/16/jquery-ui-and-wpdialogs-in-wordpress-3-9/)
126
+    wp_enqueue_script( 'wpdialogs' );
127
+    wp_enqueue_style( 'wp-jquery-ui-dialog' );
128 128
 
129
-	wp_enqueue_style( 'wordlift-reloaded', plugin_dir_url( __FILE__ ) . 'css/wordlift-reloaded.min.css' );
129
+    wp_enqueue_style( 'wordlift-reloaded', plugin_dir_url( __FILE__ ) . 'css/wordlift-reloaded.min.css' );
130 130
 
131
-	wp_enqueue_script( 'jquery-ui-autocomplete' );
131
+    wp_enqueue_script( 'jquery-ui-autocomplete' );
132 132
 
133
-	// Disable auto-save for custom entity posts only
134
-	if ( Wordlift_Entity_Service::TYPE_NAME === get_post_type() ) {
135
-		wp_dequeue_script( 'autosave' );
136
-	}
133
+    // Disable auto-save for custom entity posts only
134
+    if ( Wordlift_Entity_Service::TYPE_NAME === get_post_type() ) {
135
+        wp_dequeue_script( 'autosave' );
136
+    }
137 137
 
138 138
 }
139 139
 
@@ -149,18 +149,18 @@  discard block
 block discarded – undo
149 149
  */
150 150
 function wordlift_allowed_html( $allowedtags, $context ) {
151 151
 
152
-	if ( 'post' !== $context ) {
153
-		return $allowedtags;
154
-	}
155
-
156
-	return array_merge_recursive( $allowedtags, array(
157
-		'span' => array(
158
-			'itemscope' => true,
159
-			'itemtype'  => true,
160
-			'itemid'    => true,
161
-			'itemprop'  => true,
162
-		),
163
-	) );
152
+    if ( 'post' !== $context ) {
153
+        return $allowedtags;
154
+    }
155
+
156
+    return array_merge_recursive( $allowedtags, array(
157
+        'span' => array(
158
+            'itemscope' => true,
159
+            'itemtype'  => true,
160
+            'itemid'    => true,
161
+            'itemprop'  => true,
162
+        ),
163
+    ) );
164 164
 }
165 165
 
166 166
 add_filter( 'wp_kses_allowed_html', 'wordlift_allowed_html', 10, 2 );
@@ -174,16 +174,16 @@  discard block
 block discarded – undo
174 174
  */
175 175
 function wl_get_coordinates( $post_id ) {
176 176
 
177
-	$latitude  = wl_schema_get_value( $post_id, 'latitude' );
178
-	$longitude = wl_schema_get_value( $post_id, 'longitude' );
177
+    $latitude  = wl_schema_get_value( $post_id, 'latitude' );
178
+    $longitude = wl_schema_get_value( $post_id, 'longitude' );
179 179
 
180
-	// DO NOT set latitude/longitude to 0/0 as default values. It's a specific
181
-	// place on the globe:"The zero/zero point of this system is located in the
182
-	// Gulf of Guinea about 625 km (390 mi) south of Tema, Ghana."
183
-	return array(
184
-		'latitude'  => isset( $latitude[0] ) && is_numeric( $latitude[0] ) ? $latitude[0] : '',
185
-		'longitude' => isset( $longitude[0] ) && is_numeric( $longitude[0] ) ? $longitude[0] : '',
186
-	);
180
+    // DO NOT set latitude/longitude to 0/0 as default values. It's a specific
181
+    // place on the globe:"The zero/zero point of this system is located in the
182
+    // Gulf of Guinea about 625 km (390 mi) south of Tema, Ghana."
183
+    return array(
184
+        'latitude'  => isset( $latitude[0] ) && is_numeric( $latitude[0] ) ? $latitude[0] : '',
185
+        'longitude' => isset( $longitude[0] ) && is_numeric( $longitude[0] ) ? $longitude[0] : '',
186
+    );
187 187
 }
188 188
 
189 189
 /**
@@ -197,9 +197,9 @@  discard block
 block discarded – undo
197 197
  */
198 198
 function wl_get_image_urls( $post_id ) {
199 199
 
200
-	return Wordlift_Storage_Factory::get_instance()
201
-	                               ->post_images()
202
-	                               ->get( $post_id );
200
+    return Wordlift_Storage_Factory::get_instance()
201
+                                    ->post_images()
202
+                                    ->get( $post_id );
203 203
 
204 204
 }
205 205
 
@@ -213,24 +213,24 @@  discard block
 block discarded – undo
213 213
  */
214 214
 function wl_get_attachment_for_source_url( $parent_post_id, $source_url ) {
215 215
 
216
-	// wl_write_log( "wl_get_attachment_for_source_url [ parent post id :: $parent_post_id ][ source url :: $source_url ]" );
216
+    // wl_write_log( "wl_get_attachment_for_source_url [ parent post id :: $parent_post_id ][ source url :: $source_url ]" );
217 217
 
218
-	$posts = get_posts( array(
219
-		'post_type'      => 'attachment',
220
-		'posts_per_page' => 1,
221
-		'post_status'    => 'any',
222
-		'post_parent'    => $parent_post_id,
223
-		'meta_key'       => 'wl_source_url',
224
-		'meta_value'     => $source_url,
225
-	) );
218
+    $posts = get_posts( array(
219
+        'post_type'      => 'attachment',
220
+        'posts_per_page' => 1,
221
+        'post_status'    => 'any',
222
+        'post_parent'    => $parent_post_id,
223
+        'meta_key'       => 'wl_source_url',
224
+        'meta_value'     => $source_url,
225
+    ) );
226 226
 
227
-	// Return the found post.
228
-	if ( 1 === count( $posts ) ) {
229
-		return $posts[0];
230
-	}
227
+    // Return the found post.
228
+    if ( 1 === count( $posts ) ) {
229
+        return $posts[0];
230
+    }
231 231
 
232
-	// Return null.
233
-	return null;
232
+    // Return null.
233
+    return null;
234 234
 }
235 235
 
236 236
 /**
@@ -241,8 +241,8 @@  discard block
 block discarded – undo
241 241
  */
242 242
 function wl_set_source_url( $post_id, $source_url ) {
243 243
 
244
-	delete_post_meta( $post_id, 'wl_source_url' );
245
-	add_post_meta( $post_id, 'wl_source_url', $source_url );
244
+    delete_post_meta( $post_id, 'wl_source_url' );
245
+    add_post_meta( $post_id, 'wl_source_url', $source_url );
246 246
 }
247 247
 
248 248
 /**
@@ -259,7 +259,7 @@  discard block
 block discarded – undo
259 259
  */
260 260
 function wl_sanitize_uri_path( $path, $char = '_' ) {
261 261
 
262
-	return Wordlift_Uri_Service::get_instance()->sanitize_path( $path, $char );
262
+    return Wordlift_Uri_Service::get_instance()->sanitize_path( $path, $char );
263 263
 }
264 264
 
265 265
 /**
@@ -271,47 +271,47 @@  discard block
 block discarded – undo
271 271
  */
272 272
 function wl_replace_item_id_with_uri( $content ) {
273 273
 
274
-	$log = Wordlift_Log_Service::get_logger( 'wl_replace_item_id_with_uri' );
275
-	$log->trace( 'Replacing item IDs with URIs...' );
274
+    $log = Wordlift_Log_Service::get_logger( 'wl_replace_item_id_with_uri' );
275
+    $log->trace( 'Replacing item IDs with URIs...' );
276 276
 
277
-	// Strip slashes, see https://core.trac.wordpress.org/ticket/21767
278
-	$content = stripslashes( $content );
277
+    // Strip slashes, see https://core.trac.wordpress.org/ticket/21767
278
+    $content = stripslashes( $content );
279 279
 
280
-	// If any match are found.
281
-	$matches = array();
282
-	if ( 0 < preg_match_all( '/ itemid="([^"]+)"/i', $content, $matches, PREG_SET_ORDER ) ) {
280
+    // If any match are found.
281
+    $matches = array();
282
+    if ( 0 < preg_match_all( '/ itemid="([^"]+)"/i', $content, $matches, PREG_SET_ORDER ) ) {
283 283
 
284
-		foreach ( $matches as $match ) {
284
+        foreach ( $matches as $match ) {
285 285
 
286
-			// Get the item ID.
287
-			$item_id = $match[1];
286
+            // Get the item ID.
287
+            $item_id = $match[1];
288 288
 
289
-			// Get the post bound to that item ID (looking both in the 'official' URI and in the 'same-as' .
290
-			$post = Wordlift_Entity_Service::get_instance()
291
-			                               ->get_entity_post_by_uri( $item_id );
289
+            // Get the post bound to that item ID (looking both in the 'official' URI and in the 'same-as' .
290
+            $post = Wordlift_Entity_Service::get_instance()
291
+                                            ->get_entity_post_by_uri( $item_id );
292 292
 
293
-			// If no entity is found, continue to the next one.
294
-			if ( null === $post ) {
295
-				continue;
296
-			}
293
+            // If no entity is found, continue to the next one.
294
+            if ( null === $post ) {
295
+                continue;
296
+            }
297 297
 
298
-			// Get the URI for that post.
299
-			$uri = wl_get_entity_uri( $post->ID );
298
+            // Get the URI for that post.
299
+            $uri = wl_get_entity_uri( $post->ID );
300 300
 
301
-			// wl_write_log( "wl_replace_item_id_with_uri [ item id :: $item_id ][ uri :: $uri ]" );
301
+            // wl_write_log( "wl_replace_item_id_with_uri [ item id :: $item_id ][ uri :: $uri ]" );
302 302
 
303
-			// If the item ID and the URI differ, replace the item ID with the URI saved in WordPress.
304
-			if ( ! empty( $uri ) && $item_id !== $uri ) {
305
-				$uri_e   = esc_html( $uri );
306
-				$content = str_replace( " itemid=\"$item_id\"", " itemid=\"$uri_e\"", $content );
307
-			}
308
-		}
309
-	}
303
+            // If the item ID and the URI differ, replace the item ID with the URI saved in WordPress.
304
+            if ( ! empty( $uri ) && $item_id !== $uri ) {
305
+                $uri_e   = esc_html( $uri );
306
+                $content = str_replace( " itemid=\"$item_id\"", " itemid=\"$uri_e\"", $content );
307
+            }
308
+        }
309
+    }
310 310
 
311
-	// Reapply slashes.
312
-	$content = addslashes( $content );
311
+    // Reapply slashes.
312
+    $content = addslashes( $content );
313 313
 
314
-	return $content;
314
+    return $content;
315 315
 }
316 316
 
317 317
 add_filter( 'content_save_pre', 'wl_replace_item_id_with_uri', 1, 1 );
@@ -374,29 +374,29 @@  discard block
 block discarded – undo
374 374
  */
375 375
 function activate_wordlift() {
376 376
 
377
-	$log = Wordlift_Log_Service::get_logger( 'activate_wordlift' );
378
-
379
-	$log->info( 'Activating WordLift...' );
380
-
381
-	require_once plugin_dir_path( __FILE__ ) . 'includes/class-wordlift-activator.php';
382
-	Wordlift_Activator::activate();
383
-
384
-	/**
385
-	 * Tell the {@link Wordlift_Http_Api} class that we're activating, to let it run activation tasks.
386
-	 *
387
-	 * @see https://github.com/insideout10/wordlift-plugin/issues/820 related issue.
388
-	 * @since 3.19.2
389
-	 */
390
-	Wordlift_Http_Api::activate();
391
-
392
-	// Ensure the post type is registered before flushing the rewrite rules.
393
-	Wordlift_Entity_Post_Type_Service::get_instance()->register();
394
-	flush_rewrite_rules();
395
-	/**
396
-	 * @since 3.27.7
397
-	 * @see https://github.com/insideout10/wordlift-plugin/issues/1214
398
-	 */
399
-	Top_Entities::activate();
377
+    $log = Wordlift_Log_Service::get_logger( 'activate_wordlift' );
378
+
379
+    $log->info( 'Activating WordLift...' );
380
+
381
+    require_once plugin_dir_path( __FILE__ ) . 'includes/class-wordlift-activator.php';
382
+    Wordlift_Activator::activate();
383
+
384
+    /**
385
+     * Tell the {@link Wordlift_Http_Api} class that we're activating, to let it run activation tasks.
386
+     *
387
+     * @see https://github.com/insideout10/wordlift-plugin/issues/820 related issue.
388
+     * @since 3.19.2
389
+     */
390
+    Wordlift_Http_Api::activate();
391
+
392
+    // Ensure the post type is registered before flushing the rewrite rules.
393
+    Wordlift_Entity_Post_Type_Service::get_instance()->register();
394
+    flush_rewrite_rules();
395
+    /**
396
+     * @since 3.27.7
397
+     * @see https://github.com/insideout10/wordlift-plugin/issues/1214
398
+     */
399
+    Top_Entities::activate();
400 400
 }
401 401
 
402 402
 /**
@@ -405,16 +405,16 @@  discard block
 block discarded – undo
405 405
  */
406 406
 function deactivate_wordlift() {
407 407
 
408
-	require_once plugin_dir_path( __FILE__ ) . 'includes/class-wordlift-deactivator.php';
409
-	Wordlift_Deactivator::deactivate();
410
-	Wordlift_Http_Api::deactivate();
411
-	Ttl_Cache_Cleaner::deactivate();
412
-	/**
413
-	 * @since 3.27.7
414
-	 * @see https://github.com/insideout10/wordlift-plugin/issues/1214
415
-	 */
416
-	Top_Entities::deactivate();
417
-	flush_rewrite_rules();
408
+    require_once plugin_dir_path( __FILE__ ) . 'includes/class-wordlift-deactivator.php';
409
+    Wordlift_Deactivator::deactivate();
410
+    Wordlift_Http_Api::deactivate();
411
+    Ttl_Cache_Cleaner::deactivate();
412
+    /**
413
+     * @since 3.27.7
414
+     * @see https://github.com/insideout10/wordlift-plugin/issues/1214
415
+     */
416
+    Top_Entities::deactivate();
417
+    flush_rewrite_rules();
418 418
 
419 419
 }
420 420
 
@@ -437,100 +437,100 @@  discard block
 block discarded – undo
437 437
  * @since    1.0.0
438 438
  */
439 439
 function run_wordlift() {
440
-	/**
441
-	 * Filter: wl_feature__enable__widgets.
442
-	 *
443
-	 * @param bool whether the widgets needed to be registered, defaults to true.
444
-	 *
445
-	 * @return bool
446
-	 * @since 3.27.6
447
-	 */
448
-	if ( apply_filters( 'wl_feature__enable__widgets', true ) ) {
449
-		add_action( 'widgets_init', 'wl_register_chord_widget' );
450
-		add_action( 'widgets_init', 'wl_register_geo_widget' );
451
-		add_action( 'widgets_init', 'wl_register_timeline_widget' );
452
-	}
453
-	add_filter( 'widget_text', 'do_shortcode' );
454
-
455
-
456
-	/**
457
-	 * Filter: wl_feature__enable__analysis
458
-	 *
459
-	 * @param bool Whether to send api request to analysis or not
460
-	 *
461
-	 * @return bool
462
-	 * @since 3.27.6
463
-	 */
464
-	if ( apply_filters( 'wl_feature__enable__analysis', true ) ) {
465
-		add_action( 'wp_ajax_wl_analyze', 'wl_ajax_analyze_action' );
466
-	} else {
467
-		add_action( 'wp_ajax_wl_analyze', 'wl_ajax_analyze_disabled_action' );
468
-	}
469
-
470
-	/*
440
+    /**
441
+     * Filter: wl_feature__enable__widgets.
442
+     *
443
+     * @param bool whether the widgets needed to be registered, defaults to true.
444
+     *
445
+     * @return bool
446
+     * @since 3.27.6
447
+     */
448
+    if ( apply_filters( 'wl_feature__enable__widgets', true ) ) {
449
+        add_action( 'widgets_init', 'wl_register_chord_widget' );
450
+        add_action( 'widgets_init', 'wl_register_geo_widget' );
451
+        add_action( 'widgets_init', 'wl_register_timeline_widget' );
452
+    }
453
+    add_filter( 'widget_text', 'do_shortcode' );
454
+
455
+
456
+    /**
457
+     * Filter: wl_feature__enable__analysis
458
+     *
459
+     * @param bool Whether to send api request to analysis or not
460
+     *
461
+     * @return bool
462
+     * @since 3.27.6
463
+     */
464
+    if ( apply_filters( 'wl_feature__enable__analysis', true ) ) {
465
+        add_action( 'wp_ajax_wl_analyze', 'wl_ajax_analyze_action' );
466
+    } else {
467
+        add_action( 'wp_ajax_wl_analyze', 'wl_ajax_analyze_disabled_action' );
468
+    }
469
+
470
+    /*
471 471
 	 * We introduce the WordLift autoloader, since we start using classes in namespaces, i.e. Wordlift\Http.
472 472
 	 *
473 473
 	 * @since 3.21.2
474 474
 	 */
475
-	wordlift_plugin_autoload_register();
475
+    wordlift_plugin_autoload_register();
476 476
 
477
-	$plugin = new Wordlift();
478
-	$plugin->run();
477
+    $plugin = new Wordlift();
478
+    $plugin->run();
479 479
 
480
-	// Initialize the TTL Cache Cleaner.
481
-	new Ttl_Cache_Cleaner();
480
+    // Initialize the TTL Cache Cleaner.
481
+    new Ttl_Cache_Cleaner();
482 482
 
483
-	// Load the new Post Adapter.
484
-	new Post_Adapter();
483
+    // Load the new Post Adapter.
484
+    new Post_Adapter();
485 485
 
486
-	// Load the API Data Hooks.
487
-	new Api_Data_Hooks();
486
+    // Load the API Data Hooks.
487
+    new Api_Data_Hooks();
488 488
 
489
-	add_action( 'plugins_loaded', function () {
490
-		// Load early. **PLEASE NOTE** that features are applied only to calls that happen **AFTER** the `plugins_loaded`
491
-		// action.
492
-		require_once plugin_dir_path( __FILE__ ) . 'wordlift/features/index.php';
493
-	}, 1 );
489
+    add_action( 'plugins_loaded', function () {
490
+        // Load early. **PLEASE NOTE** that features are applied only to calls that happen **AFTER** the `plugins_loaded`
491
+        // action.
492
+        require_once plugin_dir_path( __FILE__ ) . 'wordlift/features/index.php';
493
+    }, 1 );
494 494
 
495
-	add_action( 'plugins_loaded', function () use ( $plugin ) {
496
-		// Licenses Images.
497
-		$user_agent                   = User_Agent::get_user_agent();
498
-		$wordlift_key                 = Wordlift_Configuration_Service::get_instance()->get_key();
499
-		$api_service                  = new Default_Api_Service( apply_filters( 'wl_api_base_url', WL_CONFIG_WORDLIFT_API_URL_DEFAULT_VALUE ), 60, $user_agent, $wordlift_key );
500
-		$image_license_factory        = new Image_License_Factory();
501
-		$image_license_service        = new Image_License_Service( $api_service, $image_license_factory );
502
-		$image_license_cache          = new Ttl_Cache( 'image-license', 86400 * 30 ); // 30 days.
503
-		$cached_image_license_service = new Cached_Image_License_Service( $image_license_service, $image_license_cache );
495
+    add_action( 'plugins_loaded', function () use ( $plugin ) {
496
+        // Licenses Images.
497
+        $user_agent                   = User_Agent::get_user_agent();
498
+        $wordlift_key                 = Wordlift_Configuration_Service::get_instance()->get_key();
499
+        $api_service                  = new Default_Api_Service( apply_filters( 'wl_api_base_url', WL_CONFIG_WORDLIFT_API_URL_DEFAULT_VALUE ), 60, $user_agent, $wordlift_key );
500
+        $image_license_factory        = new Image_License_Factory();
501
+        $image_license_service        = new Image_License_Service( $api_service, $image_license_factory );
502
+        $image_license_cache          = new Ttl_Cache( 'image-license', 86400 * 30 ); // 30 days.
503
+        $cached_image_license_service = new Cached_Image_License_Service( $image_license_service, $image_license_cache );
504 504
 
505
-		$image_license_scheduler       = new Image_License_Scheduler( $image_license_service, $image_license_cache );
506
-		$image_license_cleanup_service = new Image_License_Cleanup_Service();
505
+        $image_license_scheduler       = new Image_License_Scheduler( $image_license_service, $image_license_cache );
506
+        $image_license_cleanup_service = new Image_License_Cleanup_Service();
507 507
 
508
-		// Get the cached data. If we have cached data, we load the notifier.
509
-		$image_license_data = $image_license_cache->get( Cached_Image_License_Service::GET_NON_PUBLIC_DOMAIN_IMAGES );
510
-		if ( null !== $image_license_data ) {
511
-			$image_license_page = new Image_License_Page( $image_license_data, Wordlift::get_instance()->get_version() );
512
-			new Image_License_Notifier( $image_license_data, $image_license_page );
513
-		}
508
+        // Get the cached data. If we have cached data, we load the notifier.
509
+        $image_license_data = $image_license_cache->get( Cached_Image_License_Service::GET_NON_PUBLIC_DOMAIN_IMAGES );
510
+        if ( null !== $image_license_data ) {
511
+            $image_license_page = new Image_License_Page( $image_license_data, Wordlift::get_instance()->get_version() );
512
+            new Image_License_Notifier( $image_license_data, $image_license_page );
513
+        }
514 514
 
515
-		$remove_all_images_task         = new Remove_All_Images_Task( $cached_image_license_service );
516
-		$remove_all_images_task_adapter = new Task_Ajax_Adapter( $remove_all_images_task );
515
+        $remove_all_images_task         = new Remove_All_Images_Task( $cached_image_license_service );
516
+        $remove_all_images_task_adapter = new Task_Ajax_Adapter( $remove_all_images_task );
517 517
 
518
-		$reload_data_task         = new Reload_Data_Task();
519
-		$reload_data_task_adapter = new Task_Ajax_Adapter( $reload_data_task );
518
+        $reload_data_task         = new Reload_Data_Task();
519
+        $reload_data_task_adapter = new Task_Ajax_Adapter( $reload_data_task );
520 520
 
521
-		$add_license_caption_or_remove_task         = new Add_License_Caption_Or_Remove_Task( $cached_image_license_service );
522
-		$add_license_caption_or_remove_task_adapter = new Task_Ajax_Adapter( $add_license_caption_or_remove_task );
521
+        $add_license_caption_or_remove_task         = new Add_License_Caption_Or_Remove_Task( $cached_image_license_service );
522
+        $add_license_caption_or_remove_task_adapter = new Task_Ajax_Adapter( $add_license_caption_or_remove_task );
523 523
 
524
-		$remove_all_images_task_page             = new Remove_All_Images_Page( new Task_Ajax_Adapters_Registry( $remove_all_images_task_adapter ), $plugin->get_version() );
525
-		$reload_data_task_page                   = new Reload_Data_Page( new Task_Ajax_Adapters_Registry( $reload_data_task_adapter ), $plugin->get_version() );
526
-		$add_license_caption_or_remove_task_page = new Add_License_Caption_Or_Remove_Page( new Task_Ajax_Adapters_Registry( $add_license_caption_or_remove_task_adapter ), $plugin->get_version() );
524
+        $remove_all_images_task_page             = new Remove_All_Images_Page( new Task_Ajax_Adapters_Registry( $remove_all_images_task_adapter ), $plugin->get_version() );
525
+        $reload_data_task_page                   = new Reload_Data_Page( new Task_Ajax_Adapters_Registry( $reload_data_task_adapter ), $plugin->get_version() );
526
+        $add_license_caption_or_remove_task_page = new Add_License_Caption_Or_Remove_Page( new Task_Ajax_Adapters_Registry( $add_license_caption_or_remove_task_adapter ), $plugin->get_version() );
527 527
 
528
-		new Wordlift_Products_Navigator_Shortcode_REST();
528
+        new Wordlift_Products_Navigator_Shortcode_REST();
529 529
 
530
-		// Register the Dataset module, requires `$api_service`.
531
-		require_once plugin_dir_path( __FILE__ ) . 'wordlift/dataset/index.php';
530
+        // Register the Dataset module, requires `$api_service`.
531
+        require_once plugin_dir_path( __FILE__ ) . 'wordlift/dataset/index.php';
532 532
 
533
-	} );
533
+    } );
534 534
 
535 535
 }
536 536
 
@@ -544,45 +544,45 @@  discard block
 block discarded – undo
544 544
  */
545 545
 function wordlift_plugin_autoload_register() {
546 546
 
547
-	spl_autoload_register( function ( $class_name ) {
547
+    spl_autoload_register( function ( $class_name ) {
548 548
 
549
-		// Bail out if these are not our classes.
550
-		if ( 0 !== strpos( $class_name, 'Wordlift\\' ) ) {
551
-			return false;
552
-		}
549
+        // Bail out if these are not our classes.
550
+        if ( 0 !== strpos( $class_name, 'Wordlift\\' ) ) {
551
+            return false;
552
+        }
553 553
 
554
-		$class_name_lc = strtolower( str_replace( '_', '-', $class_name ) );
554
+        $class_name_lc = strtolower( str_replace( '_', '-', $class_name ) );
555 555
 
556
-		preg_match( '|^(?:(.*)\\\\)?(.+?)$|', $class_name_lc, $matches );
556
+        preg_match( '|^(?:(.*)\\\\)?(.+?)$|', $class_name_lc, $matches );
557 557
 
558
-		$path = str_replace( '\\', DIRECTORY_SEPARATOR, $matches[1] );
559
-		$file = 'class-' . $matches[2] . '.php';
558
+        $path = str_replace( '\\', DIRECTORY_SEPARATOR, $matches[1] );
559
+        $file = 'class-' . $matches[2] . '.php';
560 560
 
561
-		$full_path = plugin_dir_path( __FILE__ ) . $path . DIRECTORY_SEPARATOR . $file;
561
+        $full_path = plugin_dir_path( __FILE__ ) . $path . DIRECTORY_SEPARATOR . $file;
562 562
 
563
-		if ( ! file_exists( $full_path ) ) {
564
-			echo( "Class $class_name not found at $full_path." );
563
+        if ( ! file_exists( $full_path ) ) {
564
+            echo( "Class $class_name not found at $full_path." );
565 565
 
566
-			return false;
567
-		}
566
+            return false;
567
+        }
568 568
 
569
-		require_once $full_path;
569
+        require_once $full_path;
570 570
 
571
-		return true;
572
-	} );
571
+        return true;
572
+    } );
573 573
 
574 574
 }
575 575
 
576 576
 function wl_block_categories( $categories, $post ) {
577
-	return array_merge(
578
-		$categories,
579
-		array(
580
-			array(
581
-				'slug'  => 'wordlift',
582
-				'title' => __( 'WordLift', 'wordlift' ),
583
-			),
584
-		)
585
-	);
577
+    return array_merge(
578
+        $categories,
579
+        array(
580
+            array(
581
+                'slug'  => 'wordlift',
582
+                'title' => __( 'WordLift', 'wordlift' ),
583
+            ),
584
+        )
585
+    );
586 586
 }
587 587
 
588 588
 add_filter( 'block_categories', 'wl_block_categories', 10, 2 );
Please login to merge, or discard this patch.
Spacing   +130 added lines, -130 removed lines patch added patch discarded remove patch
@@ -48,17 +48,17 @@  discard block
 block discarded – undo
48 48
 use Wordlift\Tasks\Task_Ajax_Adapters_Registry;
49 49
 
50 50
 // If this file is called directly, abort.
51
-if ( ! defined( 'WPINC' ) ) {
51
+if ( ! defined('WPINC')) {
52 52
 	die;
53 53
 }
54 54
 
55
-require_once plugin_dir_path( __FILE__ ) . 'vendor/autoload.php';
55
+require_once plugin_dir_path(__FILE__).'vendor/autoload.php';
56 56
 
57 57
 // Include WordLift constants.
58
-require_once( 'wordlift_constants.php' );
58
+require_once('wordlift_constants.php');
59 59
 
60 60
 // Load modules.
61
-require_once( 'modules/core/wordlift_core.php' );
61
+require_once('modules/core/wordlift_core.php');
62 62
 
63 63
 /**
64 64
  * Log to the debug.log file.
@@ -70,9 +70,9 @@  discard block
 block discarded – undo
70 70
  * @deprecated use Wordlift_Log_Service::get_instance()->info( $log );
71 71
  *
72 72
  */
73
-function wl_write_log( $log ) {
73
+function wl_write_log($log) {
74 74
 
75
-	Wordlift_Log_Service::get_instance()->debug( $log );
75
+	Wordlift_Log_Service::get_instance()->debug($log);
76 76
 
77 77
 }
78 78
 
@@ -87,9 +87,9 @@  discard block
 block discarded – undo
87 87
  * @since 3.0.0
88 88
  *
89 89
  */
90
-function wl_write_log_hide_key( $text ) {
90
+function wl_write_log_hide_key($text) {
91 91
 
92
-	return str_ireplace( wl_configuration_get_key(), '<hidden>', $text );
92
+	return str_ireplace(wl_configuration_get_key(), '<hidden>', $text);
93 93
 }
94 94
 
95 95
 /**
@@ -99,7 +99,7 @@  discard block
 block discarded – undo
99 99
 function wordlift_allowed_post_tags() {
100 100
 	global $allowedposttags;
101 101
 
102
-	$tags           = array( 'span' );
102
+	$tags           = array('span');
103 103
 	$new_attributes = array(
104 104
 		'itemscope' => array(),
105 105
 		'itemtype'  => array(),
@@ -107,15 +107,15 @@  discard block
 block discarded – undo
107 107
 		'itemid'    => array(),
108 108
 	);
109 109
 
110
-	foreach ( $tags as $tag ) {
111
-		if ( isset( $allowedposttags[ $tag ] ) && is_array( $allowedposttags[ $tag ] ) ) {
112
-			$allowedposttags[ $tag ] = array_merge( $allowedposttags[ $tag ], $new_attributes );
110
+	foreach ($tags as $tag) {
111
+		if (isset($allowedposttags[$tag]) && is_array($allowedposttags[$tag])) {
112
+			$allowedposttags[$tag] = array_merge($allowedposttags[$tag], $new_attributes);
113 113
 		}
114 114
 	}
115 115
 }
116 116
 
117 117
 // add allowed post tags.
118
-add_action( 'init', 'wordlift_allowed_post_tags' );
118
+add_action('init', 'wordlift_allowed_post_tags');
119 119
 
120 120
 /**
121 121
  * Register additional scripts for the admin UI.
@@ -123,21 +123,21 @@  discard block
 block discarded – undo
123 123
 function wordlift_admin_enqueue_scripts() {
124 124
 
125 125
 	// Added for compatibility with WordPress 3.9 (see http://make.wordpress.org/core/2014/04/16/jquery-ui-and-wpdialogs-in-wordpress-3-9/)
126
-	wp_enqueue_script( 'wpdialogs' );
127
-	wp_enqueue_style( 'wp-jquery-ui-dialog' );
126
+	wp_enqueue_script('wpdialogs');
127
+	wp_enqueue_style('wp-jquery-ui-dialog');
128 128
 
129
-	wp_enqueue_style( 'wordlift-reloaded', plugin_dir_url( __FILE__ ) . 'css/wordlift-reloaded.min.css' );
129
+	wp_enqueue_style('wordlift-reloaded', plugin_dir_url(__FILE__).'css/wordlift-reloaded.min.css');
130 130
 
131
-	wp_enqueue_script( 'jquery-ui-autocomplete' );
131
+	wp_enqueue_script('jquery-ui-autocomplete');
132 132
 
133 133
 	// Disable auto-save for custom entity posts only
134
-	if ( Wordlift_Entity_Service::TYPE_NAME === get_post_type() ) {
135
-		wp_dequeue_script( 'autosave' );
134
+	if (Wordlift_Entity_Service::TYPE_NAME === get_post_type()) {
135
+		wp_dequeue_script('autosave');
136 136
 	}
137 137
 
138 138
 }
139 139
 
140
-add_action( 'admin_enqueue_scripts', 'wordlift_admin_enqueue_scripts' );
140
+add_action('admin_enqueue_scripts', 'wordlift_admin_enqueue_scripts');
141 141
 
142 142
 /**
143 143
  * Hooked to *wp_kses_allowed_html* filter, adds microdata attributes.
@@ -147,23 +147,23 @@  discard block
 block discarded – undo
147 147
  *
148 148
  * @return array An array which contains allowed microdata attributes.
149 149
  */
150
-function wordlift_allowed_html( $allowedtags, $context ) {
150
+function wordlift_allowed_html($allowedtags, $context) {
151 151
 
152
-	if ( 'post' !== $context ) {
152
+	if ('post' !== $context) {
153 153
 		return $allowedtags;
154 154
 	}
155 155
 
156
-	return array_merge_recursive( $allowedtags, array(
156
+	return array_merge_recursive($allowedtags, array(
157 157
 		'span' => array(
158 158
 			'itemscope' => true,
159 159
 			'itemtype'  => true,
160 160
 			'itemid'    => true,
161 161
 			'itemprop'  => true,
162 162
 		),
163
-	) );
163
+	));
164 164
 }
165 165
 
166
-add_filter( 'wp_kses_allowed_html', 'wordlift_allowed_html', 10, 2 );
166
+add_filter('wp_kses_allowed_html', 'wordlift_allowed_html', 10, 2);
167 167
 
168 168
 /**
169 169
  * Get the coordinates for the specified post ID.
@@ -172,17 +172,17 @@  discard block
 block discarded – undo
172 172
  *
173 173
  * @return array|null An array of coordinates or null.
174 174
  */
175
-function wl_get_coordinates( $post_id ) {
175
+function wl_get_coordinates($post_id) {
176 176
 
177
-	$latitude  = wl_schema_get_value( $post_id, 'latitude' );
178
-	$longitude = wl_schema_get_value( $post_id, 'longitude' );
177
+	$latitude  = wl_schema_get_value($post_id, 'latitude');
178
+	$longitude = wl_schema_get_value($post_id, 'longitude');
179 179
 
180 180
 	// DO NOT set latitude/longitude to 0/0 as default values. It's a specific
181 181
 	// place on the globe:"The zero/zero point of this system is located in the
182 182
 	// Gulf of Guinea about 625 km (390 mi) south of Tema, Ghana."
183 183
 	return array(
184
-		'latitude'  => isset( $latitude[0] ) && is_numeric( $latitude[0] ) ? $latitude[0] : '',
185
-		'longitude' => isset( $longitude[0] ) && is_numeric( $longitude[0] ) ? $longitude[0] : '',
184
+		'latitude'  => isset($latitude[0]) && is_numeric($latitude[0]) ? $latitude[0] : '',
185
+		'longitude' => isset($longitude[0]) && is_numeric($longitude[0]) ? $longitude[0] : '',
186 186
 	);
187 187
 }
188 188
 
@@ -195,11 +195,11 @@  discard block
 block discarded – undo
195 195
  * @deprecated use Wordlift_Storage_Factory::get_instance()->post_images()->get( $post_id )
196 196
  *
197 197
  */
198
-function wl_get_image_urls( $post_id ) {
198
+function wl_get_image_urls($post_id) {
199 199
 
200 200
 	return Wordlift_Storage_Factory::get_instance()
201 201
 	                               ->post_images()
202
-	                               ->get( $post_id );
202
+	                               ->get($post_id);
203 203
 
204 204
 }
205 205
 
@@ -211,21 +211,21 @@  discard block
 block discarded – undo
211 211
  *
212 212
  * @return WP_Post|null A post instance or null if not found.
213 213
  */
214
-function wl_get_attachment_for_source_url( $parent_post_id, $source_url ) {
214
+function wl_get_attachment_for_source_url($parent_post_id, $source_url) {
215 215
 
216 216
 	// wl_write_log( "wl_get_attachment_for_source_url [ parent post id :: $parent_post_id ][ source url :: $source_url ]" );
217 217
 
218
-	$posts = get_posts( array(
218
+	$posts = get_posts(array(
219 219
 		'post_type'      => 'attachment',
220 220
 		'posts_per_page' => 1,
221 221
 		'post_status'    => 'any',
222 222
 		'post_parent'    => $parent_post_id,
223 223
 		'meta_key'       => 'wl_source_url',
224 224
 		'meta_value'     => $source_url,
225
-	) );
225
+	));
226 226
 
227 227
 	// Return the found post.
228
-	if ( 1 === count( $posts ) ) {
228
+	if (1 === count($posts)) {
229 229
 		return $posts[0];
230 230
 	}
231 231
 
@@ -239,10 +239,10 @@  discard block
 block discarded – undo
239 239
  * @param int $post_id The post ID.
240 240
  * @param string $source_url The source URL.
241 241
  */
242
-function wl_set_source_url( $post_id, $source_url ) {
242
+function wl_set_source_url($post_id, $source_url) {
243 243
 
244
-	delete_post_meta( $post_id, 'wl_source_url' );
245
-	add_post_meta( $post_id, 'wl_source_url', $source_url );
244
+	delete_post_meta($post_id, 'wl_source_url');
245
+	add_post_meta($post_id, 'wl_source_url', $source_url);
246 246
 }
247 247
 
248 248
 /**
@@ -257,9 +257,9 @@  discard block
 block discarded – undo
257 257
  * @see        https://codex.wordpress.org/Function_Reference/sanitize_title
258 258
  *
259 259
  */
260
-function wl_sanitize_uri_path( $path, $char = '_' ) {
260
+function wl_sanitize_uri_path($path, $char = '_') {
261 261
 
262
-	return Wordlift_Uri_Service::get_instance()->sanitize_path( $path, $char );
262
+	return Wordlift_Uri_Service::get_instance()->sanitize_path($path, $char);
263 263
 }
264 264
 
265 265
 /**
@@ -269,104 +269,104 @@  discard block
 block discarded – undo
269 269
  *
270 270
  * @return string The updated post content.
271 271
  */
272
-function wl_replace_item_id_with_uri( $content ) {
272
+function wl_replace_item_id_with_uri($content) {
273 273
 
274
-	$log = Wordlift_Log_Service::get_logger( 'wl_replace_item_id_with_uri' );
275
-	$log->trace( 'Replacing item IDs with URIs...' );
274
+	$log = Wordlift_Log_Service::get_logger('wl_replace_item_id_with_uri');
275
+	$log->trace('Replacing item IDs with URIs...');
276 276
 
277 277
 	// Strip slashes, see https://core.trac.wordpress.org/ticket/21767
278
-	$content = stripslashes( $content );
278
+	$content = stripslashes($content);
279 279
 
280 280
 	// If any match are found.
281 281
 	$matches = array();
282
-	if ( 0 < preg_match_all( '/ itemid="([^"]+)"/i', $content, $matches, PREG_SET_ORDER ) ) {
282
+	if (0 < preg_match_all('/ itemid="([^"]+)"/i', $content, $matches, PREG_SET_ORDER)) {
283 283
 
284
-		foreach ( $matches as $match ) {
284
+		foreach ($matches as $match) {
285 285
 
286 286
 			// Get the item ID.
287 287
 			$item_id = $match[1];
288 288
 
289 289
 			// Get the post bound to that item ID (looking both in the 'official' URI and in the 'same-as' .
290 290
 			$post = Wordlift_Entity_Service::get_instance()
291
-			                               ->get_entity_post_by_uri( $item_id );
291
+			                               ->get_entity_post_by_uri($item_id);
292 292
 
293 293
 			// If no entity is found, continue to the next one.
294
-			if ( null === $post ) {
294
+			if (null === $post) {
295 295
 				continue;
296 296
 			}
297 297
 
298 298
 			// Get the URI for that post.
299
-			$uri = wl_get_entity_uri( $post->ID );
299
+			$uri = wl_get_entity_uri($post->ID);
300 300
 
301 301
 			// wl_write_log( "wl_replace_item_id_with_uri [ item id :: $item_id ][ uri :: $uri ]" );
302 302
 
303 303
 			// If the item ID and the URI differ, replace the item ID with the URI saved in WordPress.
304
-			if ( ! empty( $uri ) && $item_id !== $uri ) {
305
-				$uri_e   = esc_html( $uri );
306
-				$content = str_replace( " itemid=\"$item_id\"", " itemid=\"$uri_e\"", $content );
304
+			if ( ! empty($uri) && $item_id !== $uri) {
305
+				$uri_e   = esc_html($uri);
306
+				$content = str_replace(" itemid=\"$item_id\"", " itemid=\"$uri_e\"", $content);
307 307
 			}
308 308
 		}
309 309
 	}
310 310
 
311 311
 	// Reapply slashes.
312
-	$content = addslashes( $content );
312
+	$content = addslashes($content);
313 313
 
314 314
 	return $content;
315 315
 }
316 316
 
317
-add_filter( 'content_save_pre', 'wl_replace_item_id_with_uri', 1, 1 );
317
+add_filter('content_save_pre', 'wl_replace_item_id_with_uri', 1, 1);
318 318
 
319
-require_once( 'wordlift_entity_functions.php' );
319
+require_once('wordlift_entity_functions.php');
320 320
 
321 321
 // add editor related methods.
322
-require_once( 'wordlift_editor.php' );
322
+require_once('wordlift_editor.php');
323 323
 
324 324
 // add the WordLift entity custom type.
325
-require_once( 'wordlift_entity_type.php' );
325
+require_once('wordlift_entity_type.php');
326 326
 
327 327
 // add callbacks on post save to notify data changes from wp to redlink triple store
328
-require_once( 'wordlift_to_redlink_data_push_callbacks.php' );
328
+require_once('wordlift_to_redlink_data_push_callbacks.php');
329 329
 
330
-require_once( 'modules/configuration/wordlift_configuration_settings.php' );
330
+require_once('modules/configuration/wordlift_configuration_settings.php');
331 331
 
332 332
 // Load modules
333
-require_once( 'modules/analyzer/wordlift_analyzer.php' );
334
-require_once( 'modules/linked_data/wordlift_linked_data.php' );
335
-require_once( 'modules/prefixes/wordlift_prefixes.php' );
333
+require_once('modules/analyzer/wordlift_analyzer.php');
334
+require_once('modules/linked_data/wordlift_linked_data.php');
335
+require_once('modules/prefixes/wordlift_prefixes.php');
336 336
 
337 337
 // Shortcodes
338 338
 
339
-require_once( 'modules/geo_widget/wordlift_geo_widget.php' );
340
-require_once( 'shortcodes/class-wordlift-shortcode-rest.php' );
341
-require_once( 'shortcodes/wordlift_shortcode_chord.php' );
342
-require_once( 'shortcodes/wordlift_shortcode_geomap.php' );
343
-require_once( 'shortcodes/wordlift_shortcode_field.php' );
344
-require_once( 'shortcodes/wordlift_shortcode_faceted_search.php' );
345
-require_once( 'shortcodes/wordlift_shortcode_navigator.php' );
346
-require_once( 'shortcodes/class-wordlift-products-navigator-shortcode-rest.php' );
339
+require_once('modules/geo_widget/wordlift_geo_widget.php');
340
+require_once('shortcodes/class-wordlift-shortcode-rest.php');
341
+require_once('shortcodes/wordlift_shortcode_chord.php');
342
+require_once('shortcodes/wordlift_shortcode_geomap.php');
343
+require_once('shortcodes/wordlift_shortcode_field.php');
344
+require_once('shortcodes/wordlift_shortcode_faceted_search.php');
345
+require_once('shortcodes/wordlift_shortcode_navigator.php');
346
+require_once('shortcodes/class-wordlift-products-navigator-shortcode-rest.php');
347 347
 
348
-require_once( 'widgets/wordlift_widget_geo.php' );
349
-require_once( 'widgets/class-wordlift-chord-widget.php' );
350
-require_once( 'widgets/wordlift_widget_timeline.php' );
348
+require_once('widgets/wordlift_widget_geo.php');
349
+require_once('widgets/class-wordlift-chord-widget.php');
350
+require_once('widgets/wordlift_widget_timeline.php');
351 351
 
352
-require_once( 'wordlift_redlink.php' );
352
+require_once('wordlift_redlink.php');
353 353
 
354 354
 // Add admin functions.
355 355
 // TODO: find a way to make 'admin' UI tests work.
356 356
 //if ( is_admin() ) {
357 357
 
358
-require_once( 'admin/wordlift_admin.php' );
359
-require_once( 'admin/wordlift_admin_edit_post.php' );
360
-require_once( 'admin/wordlift_admin_save_post.php' );
358
+require_once('admin/wordlift_admin.php');
359
+require_once('admin/wordlift_admin_edit_post.php');
360
+require_once('admin/wordlift_admin_save_post.php');
361 361
 
362 362
 // add the entities meta box.
363
-require_once( 'admin/wordlift_admin_meta_box_entities.php' );
363
+require_once('admin/wordlift_admin_meta_box_entities.php');
364 364
 
365 365
 // add the entity creation AJAX.
366
-require_once( 'admin/wordlift_admin_ajax_related_posts.php' );
366
+require_once('admin/wordlift_admin_ajax_related_posts.php');
367 367
 
368 368
 // Load the wl_chord TinyMCE button and configuration dialog.
369
-require_once( 'admin/wordlift_admin_shortcodes.php' );
369
+require_once('admin/wordlift_admin_shortcodes.php');
370 370
 
371 371
 /**
372 372
  * The code that runs during plugin activation.
@@ -374,11 +374,11 @@  discard block
 block discarded – undo
374 374
  */
375 375
 function activate_wordlift() {
376 376
 
377
-	$log = Wordlift_Log_Service::get_logger( 'activate_wordlift' );
377
+	$log = Wordlift_Log_Service::get_logger('activate_wordlift');
378 378
 
379
-	$log->info( 'Activating WordLift...' );
379
+	$log->info('Activating WordLift...');
380 380
 
381
-	require_once plugin_dir_path( __FILE__ ) . 'includes/class-wordlift-activator.php';
381
+	require_once plugin_dir_path(__FILE__).'includes/class-wordlift-activator.php';
382 382
 	Wordlift_Activator::activate();
383 383
 
384 384
 	/**
@@ -405,7 +405,7 @@  discard block
 block discarded – undo
405 405
  */
406 406
 function deactivate_wordlift() {
407 407
 
408
-	require_once plugin_dir_path( __FILE__ ) . 'includes/class-wordlift-deactivator.php';
408
+	require_once plugin_dir_path(__FILE__).'includes/class-wordlift-deactivator.php';
409 409
 	Wordlift_Deactivator::deactivate();
410 410
 	Wordlift_Http_Api::deactivate();
411 411
 	Ttl_Cache_Cleaner::deactivate();
@@ -418,14 +418,14 @@  discard block
 block discarded – undo
418 418
 
419 419
 }
420 420
 
421
-register_activation_hook( __FILE__, 'activate_wordlift' );
422
-register_deactivation_hook( __FILE__, 'deactivate_wordlift' );
421
+register_activation_hook(__FILE__, 'activate_wordlift');
422
+register_deactivation_hook(__FILE__, 'deactivate_wordlift');
423 423
 
424 424
 /**
425 425
  * The core plugin class that is used to define internationalization,
426 426
  * admin-specific hooks, and public-facing site hooks.
427 427
  */
428
-require plugin_dir_path( __FILE__ ) . 'includes/class-wordlift.php';
428
+require plugin_dir_path(__FILE__).'includes/class-wordlift.php';
429 429
 
430 430
 /**
431 431
  * Begins execution of the plugin.
@@ -445,12 +445,12 @@  discard block
 block discarded – undo
445 445
 	 * @return bool
446 446
 	 * @since 3.27.6
447 447
 	 */
448
-	if ( apply_filters( 'wl_feature__enable__widgets', true ) ) {
449
-		add_action( 'widgets_init', 'wl_register_chord_widget' );
450
-		add_action( 'widgets_init', 'wl_register_geo_widget' );
451
-		add_action( 'widgets_init', 'wl_register_timeline_widget' );
448
+	if (apply_filters('wl_feature__enable__widgets', true)) {
449
+		add_action('widgets_init', 'wl_register_chord_widget');
450
+		add_action('widgets_init', 'wl_register_geo_widget');
451
+		add_action('widgets_init', 'wl_register_timeline_widget');
452 452
 	}
453
-	add_filter( 'widget_text', 'do_shortcode' );
453
+	add_filter('widget_text', 'do_shortcode');
454 454
 
455 455
 
456 456
 	/**
@@ -461,10 +461,10 @@  discard block
 block discarded – undo
461 461
 	 * @return bool
462 462
 	 * @since 3.27.6
463 463
 	 */
464
-	if ( apply_filters( 'wl_feature__enable__analysis', true ) ) {
465
-		add_action( 'wp_ajax_wl_analyze', 'wl_ajax_analyze_action' );
464
+	if (apply_filters('wl_feature__enable__analysis', true)) {
465
+		add_action('wp_ajax_wl_analyze', 'wl_ajax_analyze_action');
466 466
 	} else {
467
-		add_action( 'wp_ajax_wl_analyze', 'wl_ajax_analyze_disabled_action' );
467
+		add_action('wp_ajax_wl_analyze', 'wl_ajax_analyze_disabled_action');
468 468
 	}
469 469
 
470 470
 	/*
@@ -486,49 +486,49 @@  discard block
 block discarded – undo
486 486
 	// Load the API Data Hooks.
487 487
 	new Api_Data_Hooks();
488 488
 
489
-	add_action( 'plugins_loaded', function () {
489
+	add_action('plugins_loaded', function() {
490 490
 		// Load early. **PLEASE NOTE** that features are applied only to calls that happen **AFTER** the `plugins_loaded`
491 491
 		// action.
492
-		require_once plugin_dir_path( __FILE__ ) . 'wordlift/features/index.php';
493
-	}, 1 );
492
+		require_once plugin_dir_path(__FILE__).'wordlift/features/index.php';
493
+	}, 1);
494 494
 
495
-	add_action( 'plugins_loaded', function () use ( $plugin ) {
495
+	add_action('plugins_loaded', function() use ($plugin) {
496 496
 		// Licenses Images.
497 497
 		$user_agent                   = User_Agent::get_user_agent();
498 498
 		$wordlift_key                 = Wordlift_Configuration_Service::get_instance()->get_key();
499
-		$api_service                  = new Default_Api_Service( apply_filters( 'wl_api_base_url', WL_CONFIG_WORDLIFT_API_URL_DEFAULT_VALUE ), 60, $user_agent, $wordlift_key );
499
+		$api_service                  = new Default_Api_Service(apply_filters('wl_api_base_url', WL_CONFIG_WORDLIFT_API_URL_DEFAULT_VALUE), 60, $user_agent, $wordlift_key);
500 500
 		$image_license_factory        = new Image_License_Factory();
501
-		$image_license_service        = new Image_License_Service( $api_service, $image_license_factory );
502
-		$image_license_cache          = new Ttl_Cache( 'image-license', 86400 * 30 ); // 30 days.
503
-		$cached_image_license_service = new Cached_Image_License_Service( $image_license_service, $image_license_cache );
501
+		$image_license_service        = new Image_License_Service($api_service, $image_license_factory);
502
+		$image_license_cache          = new Ttl_Cache('image-license', 86400 * 30); // 30 days.
503
+		$cached_image_license_service = new Cached_Image_License_Service($image_license_service, $image_license_cache);
504 504
 
505
-		$image_license_scheduler       = new Image_License_Scheduler( $image_license_service, $image_license_cache );
505
+		$image_license_scheduler       = new Image_License_Scheduler($image_license_service, $image_license_cache);
506 506
 		$image_license_cleanup_service = new Image_License_Cleanup_Service();
507 507
 
508 508
 		// Get the cached data. If we have cached data, we load the notifier.
509
-		$image_license_data = $image_license_cache->get( Cached_Image_License_Service::GET_NON_PUBLIC_DOMAIN_IMAGES );
510
-		if ( null !== $image_license_data ) {
511
-			$image_license_page = new Image_License_Page( $image_license_data, Wordlift::get_instance()->get_version() );
512
-			new Image_License_Notifier( $image_license_data, $image_license_page );
509
+		$image_license_data = $image_license_cache->get(Cached_Image_License_Service::GET_NON_PUBLIC_DOMAIN_IMAGES);
510
+		if (null !== $image_license_data) {
511
+			$image_license_page = new Image_License_Page($image_license_data, Wordlift::get_instance()->get_version());
512
+			new Image_License_Notifier($image_license_data, $image_license_page);
513 513
 		}
514 514
 
515
-		$remove_all_images_task         = new Remove_All_Images_Task( $cached_image_license_service );
516
-		$remove_all_images_task_adapter = new Task_Ajax_Adapter( $remove_all_images_task );
515
+		$remove_all_images_task         = new Remove_All_Images_Task($cached_image_license_service);
516
+		$remove_all_images_task_adapter = new Task_Ajax_Adapter($remove_all_images_task);
517 517
 
518 518
 		$reload_data_task         = new Reload_Data_Task();
519
-		$reload_data_task_adapter = new Task_Ajax_Adapter( $reload_data_task );
519
+		$reload_data_task_adapter = new Task_Ajax_Adapter($reload_data_task);
520 520
 
521
-		$add_license_caption_or_remove_task         = new Add_License_Caption_Or_Remove_Task( $cached_image_license_service );
522
-		$add_license_caption_or_remove_task_adapter = new Task_Ajax_Adapter( $add_license_caption_or_remove_task );
521
+		$add_license_caption_or_remove_task         = new Add_License_Caption_Or_Remove_Task($cached_image_license_service);
522
+		$add_license_caption_or_remove_task_adapter = new Task_Ajax_Adapter($add_license_caption_or_remove_task);
523 523
 
524
-		$remove_all_images_task_page             = new Remove_All_Images_Page( new Task_Ajax_Adapters_Registry( $remove_all_images_task_adapter ), $plugin->get_version() );
525
-		$reload_data_task_page                   = new Reload_Data_Page( new Task_Ajax_Adapters_Registry( $reload_data_task_adapter ), $plugin->get_version() );
526
-		$add_license_caption_or_remove_task_page = new Add_License_Caption_Or_Remove_Page( new Task_Ajax_Adapters_Registry( $add_license_caption_or_remove_task_adapter ), $plugin->get_version() );
524
+		$remove_all_images_task_page             = new Remove_All_Images_Page(new Task_Ajax_Adapters_Registry($remove_all_images_task_adapter), $plugin->get_version());
525
+		$reload_data_task_page                   = new Reload_Data_Page(new Task_Ajax_Adapters_Registry($reload_data_task_adapter), $plugin->get_version());
526
+		$add_license_caption_or_remove_task_page = new Add_License_Caption_Or_Remove_Page(new Task_Ajax_Adapters_Registry($add_license_caption_or_remove_task_adapter), $plugin->get_version());
527 527
 
528 528
 		new Wordlift_Products_Navigator_Shortcode_REST();
529 529
 
530 530
 		// Register the Dataset module, requires `$api_service`.
531
-		require_once plugin_dir_path( __FILE__ ) . 'wordlift/dataset/index.php';
531
+		require_once plugin_dir_path(__FILE__).'wordlift/dataset/index.php';
532 532
 
533 533
 	} );
534 534
 
@@ -544,24 +544,24 @@  discard block
 block discarded – undo
544 544
  */
545 545
 function wordlift_plugin_autoload_register() {
546 546
 
547
-	spl_autoload_register( function ( $class_name ) {
547
+	spl_autoload_register(function($class_name) {
548 548
 
549 549
 		// Bail out if these are not our classes.
550
-		if ( 0 !== strpos( $class_name, 'Wordlift\\' ) ) {
550
+		if (0 !== strpos($class_name, 'Wordlift\\')) {
551 551
 			return false;
552 552
 		}
553 553
 
554
-		$class_name_lc = strtolower( str_replace( '_', '-', $class_name ) );
554
+		$class_name_lc = strtolower(str_replace('_', '-', $class_name));
555 555
 
556
-		preg_match( '|^(?:(.*)\\\\)?(.+?)$|', $class_name_lc, $matches );
556
+		preg_match('|^(?:(.*)\\\\)?(.+?)$|', $class_name_lc, $matches);
557 557
 
558
-		$path = str_replace( '\\', DIRECTORY_SEPARATOR, $matches[1] );
559
-		$file = 'class-' . $matches[2] . '.php';
558
+		$path = str_replace('\\', DIRECTORY_SEPARATOR, $matches[1]);
559
+		$file = 'class-'.$matches[2].'.php';
560 560
 
561
-		$full_path = plugin_dir_path( __FILE__ ) . $path . DIRECTORY_SEPARATOR . $file;
561
+		$full_path = plugin_dir_path(__FILE__).$path.DIRECTORY_SEPARATOR.$file;
562 562
 
563
-		if ( ! file_exists( $full_path ) ) {
564
-			echo( "Class $class_name not found at $full_path." );
563
+		if ( ! file_exists($full_path)) {
564
+			echo("Class $class_name not found at $full_path.");
565 565
 
566 566
 			return false;
567 567
 		}
@@ -573,16 +573,16 @@  discard block
 block discarded – undo
573 573
 
574 574
 }
575 575
 
576
-function wl_block_categories( $categories, $post ) {
576
+function wl_block_categories($categories, $post) {
577 577
 	return array_merge(
578 578
 		$categories,
579 579
 		array(
580 580
 			array(
581 581
 				'slug'  => 'wordlift',
582
-				'title' => __( 'WordLift', 'wordlift' ),
582
+				'title' => __('WordLift', 'wordlift'),
583 583
 			),
584 584
 		)
585 585
 	);
586 586
 }
587 587
 
588
-add_filter( 'block_categories', 'wl_block_categories', 10, 2 );
588
+add_filter('block_categories', 'wl_block_categories', 10, 2);
Please login to merge, or discard this patch.
src/includes/class-wordlift.php 2 patches
Indentation   +1813 added lines, -1813 removed lines patch added patch discarded remove patch
@@ -67,1555 +67,1555 @@  discard block
 block discarded – undo
67 67
  */
68 68
 class Wordlift {
69 69
 
70
-	//<editor-fold desc="## FIELDS">
71
-
72
-	/**
73
-	 * The loader that's responsible for maintaining and registering all hooks that power
74
-	 * the plugin.
75
-	 *
76
-	 * @since    1.0.0
77
-	 * @access   protected
78
-	 * @var      Wordlift_Loader $loader Maintains and registers all hooks for the plugin.
79
-	 */
80
-	protected $loader;
81
-
82
-	/**
83
-	 * The unique identifier of this plugin.
84
-	 *
85
-	 * @since    1.0.0
86
-	 * @access   protected
87
-	 * @var      string $plugin_name The string used to uniquely identify this plugin.
88
-	 */
89
-	protected $plugin_name;
90
-
91
-	/**
92
-	 * The current version of the plugin.
93
-	 *
94
-	 * @since    1.0.0
95
-	 * @access   protected
96
-	 * @var      string $version The current version of the plugin.
97
-	 */
98
-	protected $version;
99
-
100
-	/**
101
-	 * The {@link Wordlift_Tinymce_Adapter} instance.
102
-	 *
103
-	 * @since  3.12.0
104
-	 * @access protected
105
-	 * @var \Wordlift_Tinymce_Adapter $tinymce_adapter The {@link Wordlift_Tinymce_Adapter} instance.
106
-	 */
107
-	protected $tinymce_adapter;
108
-
109
-	/**
110
-	 * The {@link Faq_Tinymce_Adapter} instance
111
-	 * @since 3.26.0
112
-	 * @access protected
113
-	 * @var Faq_Tinymce_Adapter $faq_tinymce_adapter .
114
-	 */
115
-	//protected $faq_tinymce_adapter;
116
-
117
-	/**
118
-	 * The Thumbnail service.
119
-	 *
120
-	 * @since  3.1.5
121
-	 * @access private
122
-	 * @var \Wordlift_Thumbnail_Service $thumbnail_service The Thumbnail service.
123
-	 */
124
-	private $thumbnail_service;
125
-
126
-	/**
127
-	 * The UI service.
128
-	 *
129
-	 * @since  3.2.0
130
-	 * @access private
131
-	 * @var \Wordlift_UI_Service $ui_service The UI service.
132
-	 */
133
-	private $ui_service;
134
-
135
-	/**
136
-	 * The Schema service.
137
-	 *
138
-	 * @since  3.3.0
139
-	 * @access protected
140
-	 * @var \Wordlift_Schema_Service $schema_service The Schema service.
141
-	 */
142
-	protected $schema_service;
143
-
144
-	/**
145
-	 * The Entity service.
146
-	 *
147
-	 * @since  3.1.0
148
-	 * @access protected
149
-	 * @var \Wordlift_Entity_Service $entity_service The Entity service.
150
-	 */
151
-	protected $entity_service;
152
-
153
-	/**
154
-	 * The Topic Taxonomy service.
155
-	 *
156
-	 * @since  3.5.0
157
-	 * @access private
158
-	 * @var \Wordlift_Topic_Taxonomy_Service The Topic Taxonomy service.
159
-	 */
160
-	private $topic_taxonomy_service;
161
-
162
-	/**
163
-	 * The Entity Types Taxonomy service.
164
-	 *
165
-	 * @since  3.18.0
166
-	 * @access private
167
-	 * @var \Wordlift_Entity_Type_Taxonomy_Service The Entity Types Taxonomy service.
168
-	 */
169
-	private $entity_types_taxonomy_service;
170
-
171
-	/**
172
-	 * The User service.
173
-	 *
174
-	 * @since  3.1.7
175
-	 * @access protected
176
-	 * @var \Wordlift_User_Service $user_service The User service.
177
-	 */
178
-	protected $user_service;
179
-
180
-	/**
181
-	 * The Timeline service.
182
-	 *
183
-	 * @since  3.1.0
184
-	 * @access private
185
-	 * @var \Wordlift_Timeline_Service $timeline_service The Timeline service.
186
-	 */
187
-	private $timeline_service;
188
-
189
-	/**
190
-	 * The Redirect service.
191
-	 *
192
-	 * @since  3.2.0
193
-	 * @access private
194
-	 * @var \Wordlift_Redirect_Service $redirect_service The Redirect service.
195
-	 */
196
-	private $redirect_service;
197
-
198
-	/**
199
-	 * The Notice service.
200
-	 *
201
-	 * @since  3.3.0
202
-	 * @access private
203
-	 * @var \Wordlift_Notice_Service $notice_service The Notice service.
204
-	 */
205
-	private $notice_service;
206
-
207
-	/**
208
-	 * The Entity list customization.
209
-	 *
210
-	 * @since  3.3.0
211
-	 * @access protected
212
-	 * @var \Wordlift_Entity_List_Service $entity_list_service The Entity list service.
213
-	 */
214
-	protected $entity_list_service;
215
-
216
-	/**
217
-	 * The Entity Types Taxonomy Walker.
218
-	 *
219
-	 * @since  3.1.0
220
-	 * @access private
221
-	 * @var \Wordlift_Entity_Types_Taxonomy_Walker $entity_types_taxonomy_walker The Entity Types Taxonomy Walker
222
-	 */
223
-	private $entity_types_taxonomy_walker;
224
-
225
-	/**
226
-	 * The ShareThis service.
227
-	 *
228
-	 * @since  3.2.0
229
-	 * @access private
230
-	 * @var \Wordlift_ShareThis_Service $sharethis_service The ShareThis service.
231
-	 */
232
-	private $sharethis_service;
233
-
234
-	/**
235
-	 * The PrimaShop adapter.
236
-	 *
237
-	 * @since  3.2.3
238
-	 * @access private
239
-	 * @var \Wordlift_PrimaShop_Adapter $primashop_adapter The PrimaShop adapter.
240
-	 */
241
-	private $primashop_adapter;
242
-
243
-	/**
244
-	 * The WordLift Dashboard adapter.
245
-	 *
246
-	 * @since  3.4.0
247
-	 * @access private
248
-	 * @var \Wordlift_Dashboard_Service $dashboard_service The WordLift Dashboard service;
249
-	 */
250
-	private $dashboard_service;
251
-
252
-	/**
253
-	 * The entity type service.
254
-	 *
255
-	 * @since  3.6.0
256
-	 * @access private
257
-	 * @var \Wordlift_Entity_Post_Type_Service
258
-	 */
259
-	private $entity_post_type_service;
260
-
261
-	/**
262
-	 * The entity link service used to mangle links to entities with a custom slug or even w/o a slug.
263
-	 *
264
-	 * @since  3.6.0
265
-	 * @access private
266
-	 * @var \Wordlift_Entity_Link_Service $entity_link_service The {@link Wordlift_Entity_Link_Service} instance.
267
-	 */
268
-	private $entity_link_service;
269
-
270
-	/**
271
-	 * A {@link Wordlift_Sparql_Service} instance.
272
-	 *
273
-	 * @since    3.6.0
274
-	 * @access   protected
275
-	 * @var \Wordlift_Sparql_Service $sparql_service A {@link Wordlift_Sparql_Service} instance.
276
-	 */
277
-	protected $sparql_service;
278
-
279
-	/**
280
-	 * A {@link Wordlift_Import_Service} instance.
281
-	 *
282
-	 * @since  3.6.0
283
-	 * @access private
284
-	 * @var \Wordlift_Import_Service $import_service A {@link Wordlift_Import_Service} instance.
285
-	 */
286
-	private $import_service;
287
-
288
-	/**
289
-	 * A {@link Wordlift_Rebuild_Service} instance.
290
-	 *
291
-	 * @since  3.6.0
292
-	 * @access private
293
-	 * @var \Wordlift_Rebuild_Service $rebuild_service A {@link Wordlift_Rebuild_Service} instance.
294
-	 */
295
-	private $rebuild_service;
296
-
297
-	/**
298
-	 * A {@link Wordlift_Jsonld_Service} instance.
299
-	 *
300
-	 * @since  3.7.0
301
-	 * @access protected
302
-	 * @var \Wordlift_Jsonld_Service $jsonld_service A {@link Wordlift_Jsonld_Service} instance.
303
-	 */
304
-	protected $jsonld_service;
305
-
306
-	/**
307
-	 * A {@link Wordlift_Website_Jsonld_Converter} instance.
308
-	 *
309
-	 * @since  3.14.0
310
-	 * @access protected
311
-	 * @var \Wordlift_Website_Jsonld_Converter $jsonld_website_converter A {@link Wordlift_Website_Jsonld_Converter} instance.
312
-	 */
313
-	protected $jsonld_website_converter;
314
-
315
-	/**
316
-	 * A {@link Wordlift_Property_Factory} instance.
317
-	 *
318
-	 * @since  3.7.0
319
-	 * @access private
320
-	 * @var \Wordlift_Property_Factory $property_factory
321
-	 */
322
-	private $property_factory;
323
-
324
-	/**
325
-	 * The 'Download Your Data' page.
326
-	 *
327
-	 * @since  3.6.0
328
-	 * @access private
329
-	 * @var \Wordlift_Admin_Download_Your_Data_Page $download_your_data_page The 'Download Your Data' page.
330
-	 */
331
-	private $download_your_data_page;
332
-
333
-	/**
334
-	 * The 'WordLift Settings' page.
335
-	 *
336
-	 * @since  3.11.0
337
-	 * @access protected
338
-	 * @var \Wordlift_Admin_Settings_Page $settings_page The 'WordLift Settings' page.
339
-	 */
340
-	protected $settings_page;
341
-
342
-	/**
343
-	 * The install wizard page.
344
-	 *
345
-	 * @since  3.9.0
346
-	 * @access private
347
-	 * @var \Wordlift_Admin_Setup $admin_setup The Install wizard.
348
-	 */
349
-	public $admin_setup;
350
-
351
-	/**
352
-	 * The Content Filter Service hooks up to the 'the_content' filter and provides
353
-	 * linking of entities to their pages.
354
-	 *
355
-	 * @since  3.8.0
356
-	 * @access private
357
-	 * @var \Wordlift_Content_Filter_Service $content_filter_service A {@link Wordlift_Content_Filter_Service} instance.
358
-	 */
359
-	private $content_filter_service;
360
-
361
-	/**
362
-	 * The Faq Content filter service
363
-	 * @since  3.26.0
364
-	 * @access private
365
-	 * @var Faq_Content_Filter $faq_content_filter_service A {@link Faq_Content_Filter} instance.
366
-	 */
367
-	private $faq_content_filter_service;
368
-
369
-	/**
370
-	 * A {@link Wordlift_Key_Validation_Service} instance.
371
-	 *
372
-	 * @since  3.9.0
373
-	 * @access private
374
-	 * @var Wordlift_Key_Validation_Service $key_validation_service A {@link Wordlift_Key_Validation_Service} instance.
375
-	 */
376
-	private $key_validation_service;
377
-
378
-	/**
379
-	 * A {@link Wordlift_Rating_Service} instance.
380
-	 *
381
-	 * @since  3.10.0
382
-	 * @access private
383
-	 * @var \Wordlift_Rating_Service $rating_service A {@link Wordlift_Rating_Service} instance.
384
-	 */
385
-	private $rating_service;
386
-
387
-	/**
388
-	 * A {@link Wordlift_Post_To_Jsonld_Converter} instance.
389
-	 *
390
-	 * @since  3.10.0
391
-	 * @access protected
392
-	 * @var \Wordlift_Post_To_Jsonld_Converter $post_to_jsonld_converter A {@link Wordlift_Post_To_Jsonld_Converter} instance.
393
-	 */
394
-	protected $post_to_jsonld_converter;
395
-
396
-	/**
397
-	 * A {@link Wordlift_Configuration_Service} instance.
398
-	 *
399
-	 * @since  3.10.0
400
-	 * @access protected
401
-	 * @var \Wordlift_Configuration_Service $configuration_service A {@link Wordlift_Configuration_Service} instance.
402
-	 */
403
-	protected $configuration_service;
404
-
405
-	/**
406
-	 * A {@link Wordlift_Install_Service} instance.
407
-	 *
408
-	 * @since  3.18.0
409
-	 * @access protected
410
-	 * @var \Wordlift_Install_Service $install_service A {@link Wordlift_Install_Service} instance.
411
-	 */
412
-	protected $install_service;
413
-
414
-	/**
415
-	 * A {@link Wordlift_Entity_Type_Service} instance.
416
-	 *
417
-	 * @since  3.10.0
418
-	 * @access protected
419
-	 * @var \Wordlift_Entity_Type_Service $entity_type_service A {@link Wordlift_Entity_Type_Service} instance.
420
-	 */
421
-	protected $entity_type_service;
422
-
423
-	/**
424
-	 * A {@link Wordlift_Entity_Post_To_Jsonld_Converter} instance.
425
-	 *
426
-	 * @since  3.10.0
427
-	 * @access protected
428
-	 * @var \Wordlift_Entity_Post_To_Jsonld_Converter $entity_post_to_jsonld_converter A {@link Wordlift_Entity_Post_To_Jsonld_Converter} instance.
429
-	 */
430
-	protected $entity_post_to_jsonld_converter;
431
-
432
-	/**
433
-	 * A {@link Wordlift_Postid_To_Jsonld_Converter} instance.
434
-	 *
435
-	 * @since  3.10.0
436
-	 * @access protected
437
-	 * @var \Wordlift_Postid_To_Jsonld_Converter $postid_to_jsonld_converter A {@link Wordlift_Postid_To_Jsonld_Converter} instance.
438
-	 */
439
-	protected $postid_to_jsonld_converter;
440
-
441
-	/**
442
-	 * The {@link Wordlift_Admin_Status_Page} class.
443
-	 *
444
-	 * @since  3.9.8
445
-	 * @access private
446
-	 * @var \Wordlift_Admin_Status_Page $status_page The {@link Wordlift_Admin_Status_Page} class.
447
-	 */
448
-	private $status_page;
449
-
450
-	/**
451
-	 * The {@link Wordlift_Category_Taxonomy_Service} instance.
452
-	 *
453
-	 * @since  3.11.0
454
-	 * @access protected
455
-	 * @var \Wordlift_Category_Taxonomy_Service $category_taxonomy_service The {@link Wordlift_Category_Taxonomy_Service} instance.
456
-	 */
457
-	protected $category_taxonomy_service;
458
-
459
-	/**
460
-	 * The {@link Wordlift_Entity_Page_Service} instance.
461
-	 *
462
-	 * @since  3.11.0
463
-	 * @access protected
464
-	 * @var \Wordlift_Entity_Page_Service $entity_page_service The {@link Wordlift_Entity_Page_Service} instance.
465
-	 */
466
-	protected $entity_page_service;
467
-
468
-	/**
469
-	 * The {@link Wordlift_Admin_Settings_Page_Action_Link} class.
470
-	 *
471
-	 * @since  3.11.0
472
-	 * @access protected
473
-	 * @var \Wordlift_Admin_Settings_Page_Action_Link $settings_page_action_link The {@link Wordlift_Admin_Settings_Page_Action_Link} class.
474
-	 */
475
-	protected $settings_page_action_link;
476
-
477
-	/**
478
-	 * The {@link Wordlift_Admin_Settings_Page_Action_Link} class.
479
-	 *
480
-	 * @since  3.11.0
481
-	 * @access protected
482
-	 * @var \Wordlift_Admin_Settings_Page_Action_Link $settings_page_action_link The {@link Wordlift_Admin_Settings_Page_Action_Link} class.
483
-	 */
484
-	protected $analytics_settings_page_action_link;
485
-
486
-	/**
487
-	 * The {@link Wordlift_Analytics_Connect} class.
488
-	 *
489
-	 * @since  3.11.0
490
-	 * @access protected
491
-	 * @var \Wordlift_Analytics_Connect $analytics_connect The {@link Wordlift_Analytics_Connect} class.
492
-	 */
493
-	protected $analytics_connect;
494
-
495
-	/**
496
-	 * The {@link Wordlift_Publisher_Ajax_Adapter} instance.
497
-	 *
498
-	 * @since  3.11.0
499
-	 * @access protected
500
-	 * @var \Wordlift_Publisher_Ajax_Adapter $publisher_ajax_adapter The {@link Wordlift_Publisher_Ajax_Adapter} instance.
501
-	 */
502
-	protected $publisher_ajax_adapter;
503
-
504
-	/**
505
-	 * The {@link Wordlift_Admin_Input_Element} element renderer.
506
-	 *
507
-	 * @since  3.11.0
508
-	 * @access protected
509
-	 * @var \Wordlift_Admin_Input_Element $input_element The {@link Wordlift_Admin_Input_Element} element renderer.
510
-	 */
511
-	protected $input_element;
512
-
513
-	/**
514
-	 * The {@link Wordlift_Admin_Radio_Input_Element} element renderer.
515
-	 *
516
-	 * @since  3.13.0
517
-	 * @access protected
518
-	 * @var \Wordlift_Admin_Radio_Input_Element $radio_input_element The {@link Wordlift_Admin_Radio_Input_Element} element renderer.
519
-	 */
520
-	protected $radio_input_element;
521
-
522
-	/**
523
-	 * The {@link Wordlift_Admin_Language_Select_Element} element renderer.
524
-	 *
525
-	 * @since  3.11.0
526
-	 * @access protected
527
-	 * @var \Wordlift_Admin_Language_Select_Element $language_select_element The {@link Wordlift_Admin_Language_Select_Element} element renderer.
528
-	 */
529
-	protected $language_select_element;
530
-
531
-	/**
532
-	 * The {@link Wordlift_Admin_Country_Select_Element} element renderer.
533
-	 *
534
-	 * @since  3.18.0
535
-	 * @access protected
536
-	 * @var \Wordlift_Admin_Country_Select_Element $country_select_element The {@link Wordlift_Admin_Country_Select_Element} element renderer.
537
-	 */
538
-	protected $country_select_element;
539
-
540
-	/**
541
-	 * The {@link Wordlift_Admin_Publisher_Element} element renderer.
542
-	 *
543
-	 * @since  3.11.0
544
-	 * @access protected
545
-	 * @var \Wordlift_Admin_Publisher_Element $publisher_element The {@link Wordlift_Admin_Publisher_Element} element renderer.
546
-	 */
547
-	protected $publisher_element;
548
-
549
-	/**
550
-	 * The {@link Wordlift_Admin_Select2_Element} element renderer.
551
-	 *
552
-	 * @since  3.11.0
553
-	 * @access protected
554
-	 * @var \Wordlift_Admin_Select2_Element $select2_element The {@link Wordlift_Admin_Select2_Element} element renderer.
555
-	 */
556
-	protected $select2_element;
557
-
558
-	/**
559
-	 * The controller for the entity type list admin page
560
-	 *
561
-	 * @since  3.11.0
562
-	 * @access private
563
-	 * @var \Wordlift_Admin_Entity_Taxonomy_List_Page $entity_type_admin_page The {@link Wordlift_Admin_Entity_Taxonomy_List_Page} class.
564
-	 */
565
-	private $entity_type_admin_page;
566
-
567
-	/**
568
-	 * The controller for the entity type settings admin page
569
-	 *
570
-	 * @since  3.11.0
571
-	 * @access private
572
-	 * @var \Wordlift_Admin_Entity_Type_Settings $entity_type_settings_admin_page The {@link Wordlift_Admin_Entity_Type_Settings} class.
573
-	 */
574
-	private $entity_type_settings_admin_page;
575
-
576
-	/**
577
-	 * The {@link Wordlift_Related_Entities_Cloud_Widget} instance.
578
-	 *
579
-	 * @since  3.11.0
580
-	 * @access protected
581
-	 * @var \Wordlift_Related_Entities_Cloud_Widget $related_entities_cloud_widget The {@link Wordlift_Related_Entities_Cloud_Widget} instance.
582
-	 */
583
-	protected $related_entities_cloud_widget;
584
-
585
-	/**
586
-	 * The {@link Wordlift_Admin_Author_Element} instance.
587
-	 *
588
-	 * @since  3.14.0
589
-	 * @access protected
590
-	 * @var \Wordlift_Admin_Author_Element $author_element The {@link Wordlift_Admin_Author_Element} instance.
591
-	 */
592
-	protected $author_element;
593
-
594
-	/**
595
-	 * The {@link Wordlift_Sample_Data_Service} instance.
596
-	 *
597
-	 * @since  3.12.0
598
-	 * @access protected
599
-	 * @var \Wordlift_Sample_Data_Service $sample_data_service The {@link Wordlift_Sample_Data_Service} instance.
600
-	 */
601
-	protected $sample_data_service;
602
-
603
-	/**
604
-	 * The {@link Wordlift_Sample_Data_Ajax_Adapter} instance.
605
-	 *
606
-	 * @since  3.12.0
607
-	 * @access protected
608
-	 * @var \Wordlift_Sample_Data_Ajax_Adapter $sample_data_ajax_adapter The {@link Wordlift_Sample_Data_Ajax_Adapter} instance.
609
-	 */
610
-	protected $sample_data_ajax_adapter;
611
-
612
-	/**
613
-	 * The {@link Wordlift_Relation_Rebuild_Service} instance.
614
-	 *
615
-	 * @since  3.14.3
616
-	 * @access private
617
-	 * @var \Wordlift_Relation_Rebuild_Service $relation_rebuild_service The {@link Wordlift_Relation_Rebuild_Service} instance.
618
-	 */
619
-	private $relation_rebuild_service;
620
-
621
-	/**
622
-	 * The {@link Wordlift_Relation_Rebuild_Adapter} instance.
623
-	 *
624
-	 * @since  3.14.3
625
-	 * @access private
626
-	 * @var \Wordlift_Relation_Rebuild_Adapter $relation_rebuild_adapter The {@link Wordlift_Relation_Rebuild_Adapter} instance.
627
-	 */
628
-	private $relation_rebuild_adapter;
629
-
630
-	/**
631
-	 * The {@link Wordlift_Reference_Rebuild_Service} instance.
632
-	 *
633
-	 * @since  3.18.0
634
-	 * @access private
635
-	 * @var \Wordlift_Reference_Rebuild_Service $reference_rebuild_service The {@link Wordlift_Reference_Rebuild_Service} instance.
636
-	 */
637
-	private $reference_rebuild_service;
638
-
639
-	/**
640
-	 * The {@link Wordlift_Google_Analytics_Export_Service} instance.
641
-	 *
642
-	 * @since  3.16.0
643
-	 * @access protected
644
-	 * @var \Wordlift_Google_Analytics_Export_Service $google_analytics_export_service The {@link Wordlift_Google_Analytics_Export_Service} instance.
645
-	 */
646
-	protected $google_analytics_export_service;
647
-
648
-	/**
649
-	 * {@link Wordlift}'s singleton instance.
650
-	 *
651
-	 * @since  3.15.0
652
-	 * @access protected
653
-	 * @var \Wordlift_Entity_Type_Adapter $entity_type_adapter The {@link Wordlift_Entity_Type_Adapter} instance.
654
-	 */
655
-	protected $entity_type_adapter;
656
-
657
-	/**
658
-	 * The {@link Wordlift_Storage_Factory} instance.
659
-	 *
660
-	 * @since  3.15.0
661
-	 * @access protected
662
-	 * @var \Wordlift_Storage_Factory $storage_factory The {@link Wordlift_Storage_Factory} instance.
663
-	 */
664
-	protected $storage_factory;
665
-
666
-	/**
667
-	 * The {@link Wordlift_Sparql_Tuple_Rendition_Factory} instance.
668
-	 *
669
-	 * @since  3.15.0
670
-	 * @access protected
671
-	 * @var \Wordlift_Sparql_Tuple_Rendition_Factory $rendition_factory The {@link Wordlift_Sparql_Tuple_Rendition_Factory} instance.
672
-	 */
673
-	protected $rendition_factory;
674
-
675
-	/**
676
-	 * The {@link Wordlift_Autocomplete_Adapter} instance.
677
-	 *
678
-	 * @since  3.15.0
679
-	 * @access private
680
-	 * @var \Wordlift_Autocomplete_Adapter $autocomplete_adapter The {@link Wordlift_Autocomplete_Adapter} instance.
681
-	 */
682
-	private $autocomplete_adapter;
683
-
684
-	/**
685
-	 * The {@link Wordlift_Relation_Service} instance.
686
-	 *
687
-	 * @since  3.15.0
688
-	 * @access protected
689
-	 * @var \Wordlift_Relation_Service $relation_service The {@link Wordlift_Relation_Service} instance.
690
-	 */
691
-	protected $relation_service;
692
-
693
-	/**
694
-	 * The {@link Wordlift_Cached_Post_Converter} instance.
695
-	 *
696
-	 * @since  3.16.0
697
-	 * @access protected
698
-	 * @var  \Wordlift_Cached_Post_Converter $cached_postid_to_jsonld_converter The {@link Wordlift_Cached_Post_Converter} instance.
699
-	 *
700
-	 */
701
-	protected $cached_postid_to_jsonld_converter;
702
-
703
-	/**
704
-	 * The {@link Wordlift_Entity_Uri_Service} instance.
705
-	 *
706
-	 * @since  3.16.3
707
-	 * @access protected
708
-	 * @var \Wordlift_Entity_Uri_Service $entity_uri_service The {@link Wordlift_Entity_Uri_Service} instance.
709
-	 */
710
-	protected $entity_uri_service;
711
-
712
-	/**
713
-	 * The {@link Wordlift_Publisher_Service} instance.
714
-	 *
715
-	 * @since  3.19.0
716
-	 * @access protected
717
-	 * @var \Wordlift_Publisher_Service $publisher_service The {@link Wordlift_Publisher_Service} instance.
718
-	 */
719
-	protected $publisher_service;
720
-
721
-	/**
722
-	 * The {@link Wordlift_Context_Cards_Service} instance.
723
-	 *
724
-	 * @var \Wordlift_Context_Cards_Service The {@link Wordlift_Context_Cards_Service} instance.
725
-	 */
726
-	protected $context_cards_service;
727
-
728
-	/**
729
-	 * {@link Wordlift}'s singleton instance.
730
-	 *
731
-	 * @since  3.11.2
732
-	 * @access private
733
-	 * @var Wordlift $instance {@link Wordlift}'s singleton instance.
734
-	 */
735
-	private static $instance;
736
-
737
-	//</editor-fold>
738
-
739
-	/**
740
-	 * Define the core functionality of the plugin.
741
-	 *
742
-	 * Set the plugin name and the plugin version that can be used throughout the plugin.
743
-	 * Load the dependencies, define the locale, and set the hooks for the admin area and
744
-	 * the public-facing side of the site.
745
-	 *
746
-	 * @since    1.0.0
747
-	 */
748
-	public function __construct() {
749
-
750
-		self::$instance = $this;
751
-
752
-		$this->plugin_name = 'wordlift';
753
-		$this->version     = '3.27.7.2';
754
-		$this->load_dependencies();
755
-		$this->set_locale();
756
-		$this->define_admin_hooks();
757
-		$this->define_public_hooks();
758
-
759
-		// If we're in `WP_CLI` load the related files.
760
-		if ( class_exists( 'WP_CLI' ) ) {
761
-			$this->load_cli_dependencies();
762
-		}
763
-
764
-	}
765
-
766
-	/**
767
-	 * Get the singleton instance.
768
-	 *
769
-	 * @return Wordlift The {@link Wordlift} singleton instance.
770
-	 * @since 3.11.2
771
-	 *
772
-	 */
773
-	public static function get_instance() {
774
-
775
-		return self::$instance;
776
-	}
777
-
778
-	/**
779
-	 * Load the required dependencies for this plugin.
780
-	 *
781
-	 * Include the following files that make up the plugin:
782
-	 *
783
-	 * - Wordlift_Loader. Orchestrates the hooks of the plugin.
784
-	 * - Wordlift_i18n. Defines internationalization functionality.
785
-	 * - Wordlift_Admin. Defines all hooks for the admin area.
786
-	 * - Wordlift_Public. Defines all hooks for the public side of the site.
787
-	 *
788
-	 * Create an instance of the loader which will be used to register the hooks
789
-	 * with WordPress.
790
-	 *
791
-	 * @throws Exception
792
-	 * @since    1.0.0
793
-	 * @access   private
794
-	 */
795
-	private function load_dependencies() {
796
-
797
-		/**
798
-		 * The class responsible for orchestrating the actions and filters of the
799
-		 * core plugin.
800
-		 */
801
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-loader.php';
802
-
803
-		// The class responsible for plugin uninstall.
804
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-deactivator-feedback.php';
805
-
806
-		/**
807
-		 * The class responsible for defining internationalization functionality
808
-		 * of the plugin.
809
-		 */
810
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-i18n.php';
811
-
812
-		/**
813
-		 * WordLift's supported languages.
814
-		 */
815
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-languages.php';
816
-
817
-		/**
818
-		 * WordLift's supported countries.
819
-		 */
820
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-countries.php';
821
-
822
-		/**
823
-		 * Provide support functions to sanitize data.
824
-		 */
825
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-sanitizer.php';
826
-
827
-		/** Services. */
828
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-log-service.php';
829
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-http-api.php';
830
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-redirect-service.php';
831
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-configuration-service.php';
832
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-entity-post-type-service.php';
833
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-entity-type-service.php';
834
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-entity-link-service.php';
835
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-linked-data-service.php';
836
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-relation-service.php';
837
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-image-service.php';
838
-
839
-		/**
840
-		 * The Query builder.
841
-		 */
842
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-query-builder.php';
843
-
844
-		/**
845
-		 * The Schema service.
846
-		 */
847
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-schema-service.php';
848
-
849
-		/**
850
-		 * The schema:url property service.
851
-		 */
852
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-property-service.php';
853
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-schema-url-property-service.php';
854
-
855
-		/**
856
-		 * The UI service.
857
-		 */
858
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-ui-service.php';
859
-
860
-		/**
861
-		 * The Thumbnail service.
862
-		 */
863
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-thumbnail-service.php';
864
-
865
-		/**
866
-		 * The Entity Types Taxonomy service.
867
-		 */
868
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-entity-type-taxonomy-service.php';
869
-
870
-		/**
871
-		 * The Entity service.
872
-		 */
873
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-entity-uri-service.php';
874
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-entity-service.php';
875
-
876
-		// Add the entity rating service.
877
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-rating-service.php';
878
-
879
-		/**
880
-		 * The User service.
881
-		 */
882
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-user-service.php';
883
-
884
-		/**
885
-		 * The Timeline service.
886
-		 */
887
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-timeline-service.php';
888
-
889
-		/**
890
-		 * The Topic Taxonomy service.
891
-		 */
892
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-topic-taxonomy-service.php';
893
-
894
-		/**
895
-		 * The SPARQL service.
896
-		 */
897
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-sparql-service.php';
898
-
899
-		/**
900
-		 * The WordLift import service.
901
-		 */
902
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-import-service.php';
903
-
904
-		/**
905
-		 * The WordLift URI service.
906
-		 */
907
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-uri-service.php';
908
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-property-factory.php';
909
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-sample-data-service.php';
910
-
911
-		/**
912
-		 * The WordLift rebuild service, used to rebuild the remote dataset using the local data.
913
-		 */
914
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/rebuild/class-wordlift-listable.php';
915
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/rebuild/class-wordlift-rebuild-service.php';
916
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/rebuild/class-wordlift-reference-rebuild-service.php';
917
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/rebuild/class-wordlift-relation-rebuild-service.php';
918
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/rebuild/class-wordlift-relation-rebuild-adapter.php';
919
-
920
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/properties/class-wordlift-property-getter-factory.php';
921
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-attachment-service.php';
922
-
923
-		/**
924
-		 * Load the converters.
925
-		 */
926
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/intf-wordlift-post-converter.php';
927
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-abstract-post-to-jsonld-converter.php';
928
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-postid-to-jsonld-converter.php';
929
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-entity-post-to-jsonld-converter.php';
930
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-post-to-jsonld-converter.php';
931
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-jsonld-website-converter.php';
932
-
933
-		/**
934
-		 * Load cache-related files.
935
-		 */
936
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/cache/require.php';
937
-
938
-		/**
939
-		 * Load the content filter.
940
-		 */
941
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-content-filter-service.php';
942
-
943
-		/*
70
+    //<editor-fold desc="## FIELDS">
71
+
72
+    /**
73
+     * The loader that's responsible for maintaining and registering all hooks that power
74
+     * the plugin.
75
+     *
76
+     * @since    1.0.0
77
+     * @access   protected
78
+     * @var      Wordlift_Loader $loader Maintains and registers all hooks for the plugin.
79
+     */
80
+    protected $loader;
81
+
82
+    /**
83
+     * The unique identifier of this plugin.
84
+     *
85
+     * @since    1.0.0
86
+     * @access   protected
87
+     * @var      string $plugin_name The string used to uniquely identify this plugin.
88
+     */
89
+    protected $plugin_name;
90
+
91
+    /**
92
+     * The current version of the plugin.
93
+     *
94
+     * @since    1.0.0
95
+     * @access   protected
96
+     * @var      string $version The current version of the plugin.
97
+     */
98
+    protected $version;
99
+
100
+    /**
101
+     * The {@link Wordlift_Tinymce_Adapter} instance.
102
+     *
103
+     * @since  3.12.0
104
+     * @access protected
105
+     * @var \Wordlift_Tinymce_Adapter $tinymce_adapter The {@link Wordlift_Tinymce_Adapter} instance.
106
+     */
107
+    protected $tinymce_adapter;
108
+
109
+    /**
110
+     * The {@link Faq_Tinymce_Adapter} instance
111
+     * @since 3.26.0
112
+     * @access protected
113
+     * @var Faq_Tinymce_Adapter $faq_tinymce_adapter .
114
+     */
115
+    //protected $faq_tinymce_adapter;
116
+
117
+    /**
118
+     * The Thumbnail service.
119
+     *
120
+     * @since  3.1.5
121
+     * @access private
122
+     * @var \Wordlift_Thumbnail_Service $thumbnail_service The Thumbnail service.
123
+     */
124
+    private $thumbnail_service;
125
+
126
+    /**
127
+     * The UI service.
128
+     *
129
+     * @since  3.2.0
130
+     * @access private
131
+     * @var \Wordlift_UI_Service $ui_service The UI service.
132
+     */
133
+    private $ui_service;
134
+
135
+    /**
136
+     * The Schema service.
137
+     *
138
+     * @since  3.3.0
139
+     * @access protected
140
+     * @var \Wordlift_Schema_Service $schema_service The Schema service.
141
+     */
142
+    protected $schema_service;
143
+
144
+    /**
145
+     * The Entity service.
146
+     *
147
+     * @since  3.1.0
148
+     * @access protected
149
+     * @var \Wordlift_Entity_Service $entity_service The Entity service.
150
+     */
151
+    protected $entity_service;
152
+
153
+    /**
154
+     * The Topic Taxonomy service.
155
+     *
156
+     * @since  3.5.0
157
+     * @access private
158
+     * @var \Wordlift_Topic_Taxonomy_Service The Topic Taxonomy service.
159
+     */
160
+    private $topic_taxonomy_service;
161
+
162
+    /**
163
+     * The Entity Types Taxonomy service.
164
+     *
165
+     * @since  3.18.0
166
+     * @access private
167
+     * @var \Wordlift_Entity_Type_Taxonomy_Service The Entity Types Taxonomy service.
168
+     */
169
+    private $entity_types_taxonomy_service;
170
+
171
+    /**
172
+     * The User service.
173
+     *
174
+     * @since  3.1.7
175
+     * @access protected
176
+     * @var \Wordlift_User_Service $user_service The User service.
177
+     */
178
+    protected $user_service;
179
+
180
+    /**
181
+     * The Timeline service.
182
+     *
183
+     * @since  3.1.0
184
+     * @access private
185
+     * @var \Wordlift_Timeline_Service $timeline_service The Timeline service.
186
+     */
187
+    private $timeline_service;
188
+
189
+    /**
190
+     * The Redirect service.
191
+     *
192
+     * @since  3.2.0
193
+     * @access private
194
+     * @var \Wordlift_Redirect_Service $redirect_service The Redirect service.
195
+     */
196
+    private $redirect_service;
197
+
198
+    /**
199
+     * The Notice service.
200
+     *
201
+     * @since  3.3.0
202
+     * @access private
203
+     * @var \Wordlift_Notice_Service $notice_service The Notice service.
204
+     */
205
+    private $notice_service;
206
+
207
+    /**
208
+     * The Entity list customization.
209
+     *
210
+     * @since  3.3.0
211
+     * @access protected
212
+     * @var \Wordlift_Entity_List_Service $entity_list_service The Entity list service.
213
+     */
214
+    protected $entity_list_service;
215
+
216
+    /**
217
+     * The Entity Types Taxonomy Walker.
218
+     *
219
+     * @since  3.1.0
220
+     * @access private
221
+     * @var \Wordlift_Entity_Types_Taxonomy_Walker $entity_types_taxonomy_walker The Entity Types Taxonomy Walker
222
+     */
223
+    private $entity_types_taxonomy_walker;
224
+
225
+    /**
226
+     * The ShareThis service.
227
+     *
228
+     * @since  3.2.0
229
+     * @access private
230
+     * @var \Wordlift_ShareThis_Service $sharethis_service The ShareThis service.
231
+     */
232
+    private $sharethis_service;
233
+
234
+    /**
235
+     * The PrimaShop adapter.
236
+     *
237
+     * @since  3.2.3
238
+     * @access private
239
+     * @var \Wordlift_PrimaShop_Adapter $primashop_adapter The PrimaShop adapter.
240
+     */
241
+    private $primashop_adapter;
242
+
243
+    /**
244
+     * The WordLift Dashboard adapter.
245
+     *
246
+     * @since  3.4.0
247
+     * @access private
248
+     * @var \Wordlift_Dashboard_Service $dashboard_service The WordLift Dashboard service;
249
+     */
250
+    private $dashboard_service;
251
+
252
+    /**
253
+     * The entity type service.
254
+     *
255
+     * @since  3.6.0
256
+     * @access private
257
+     * @var \Wordlift_Entity_Post_Type_Service
258
+     */
259
+    private $entity_post_type_service;
260
+
261
+    /**
262
+     * The entity link service used to mangle links to entities with a custom slug or even w/o a slug.
263
+     *
264
+     * @since  3.6.0
265
+     * @access private
266
+     * @var \Wordlift_Entity_Link_Service $entity_link_service The {@link Wordlift_Entity_Link_Service} instance.
267
+     */
268
+    private $entity_link_service;
269
+
270
+    /**
271
+     * A {@link Wordlift_Sparql_Service} instance.
272
+     *
273
+     * @since    3.6.0
274
+     * @access   protected
275
+     * @var \Wordlift_Sparql_Service $sparql_service A {@link Wordlift_Sparql_Service} instance.
276
+     */
277
+    protected $sparql_service;
278
+
279
+    /**
280
+     * A {@link Wordlift_Import_Service} instance.
281
+     *
282
+     * @since  3.6.0
283
+     * @access private
284
+     * @var \Wordlift_Import_Service $import_service A {@link Wordlift_Import_Service} instance.
285
+     */
286
+    private $import_service;
287
+
288
+    /**
289
+     * A {@link Wordlift_Rebuild_Service} instance.
290
+     *
291
+     * @since  3.6.0
292
+     * @access private
293
+     * @var \Wordlift_Rebuild_Service $rebuild_service A {@link Wordlift_Rebuild_Service} instance.
294
+     */
295
+    private $rebuild_service;
296
+
297
+    /**
298
+     * A {@link Wordlift_Jsonld_Service} instance.
299
+     *
300
+     * @since  3.7.0
301
+     * @access protected
302
+     * @var \Wordlift_Jsonld_Service $jsonld_service A {@link Wordlift_Jsonld_Service} instance.
303
+     */
304
+    protected $jsonld_service;
305
+
306
+    /**
307
+     * A {@link Wordlift_Website_Jsonld_Converter} instance.
308
+     *
309
+     * @since  3.14.0
310
+     * @access protected
311
+     * @var \Wordlift_Website_Jsonld_Converter $jsonld_website_converter A {@link Wordlift_Website_Jsonld_Converter} instance.
312
+     */
313
+    protected $jsonld_website_converter;
314
+
315
+    /**
316
+     * A {@link Wordlift_Property_Factory} instance.
317
+     *
318
+     * @since  3.7.0
319
+     * @access private
320
+     * @var \Wordlift_Property_Factory $property_factory
321
+     */
322
+    private $property_factory;
323
+
324
+    /**
325
+     * The 'Download Your Data' page.
326
+     *
327
+     * @since  3.6.0
328
+     * @access private
329
+     * @var \Wordlift_Admin_Download_Your_Data_Page $download_your_data_page The 'Download Your Data' page.
330
+     */
331
+    private $download_your_data_page;
332
+
333
+    /**
334
+     * The 'WordLift Settings' page.
335
+     *
336
+     * @since  3.11.0
337
+     * @access protected
338
+     * @var \Wordlift_Admin_Settings_Page $settings_page The 'WordLift Settings' page.
339
+     */
340
+    protected $settings_page;
341
+
342
+    /**
343
+     * The install wizard page.
344
+     *
345
+     * @since  3.9.0
346
+     * @access private
347
+     * @var \Wordlift_Admin_Setup $admin_setup The Install wizard.
348
+     */
349
+    public $admin_setup;
350
+
351
+    /**
352
+     * The Content Filter Service hooks up to the 'the_content' filter and provides
353
+     * linking of entities to their pages.
354
+     *
355
+     * @since  3.8.0
356
+     * @access private
357
+     * @var \Wordlift_Content_Filter_Service $content_filter_service A {@link Wordlift_Content_Filter_Service} instance.
358
+     */
359
+    private $content_filter_service;
360
+
361
+    /**
362
+     * The Faq Content filter service
363
+     * @since  3.26.0
364
+     * @access private
365
+     * @var Faq_Content_Filter $faq_content_filter_service A {@link Faq_Content_Filter} instance.
366
+     */
367
+    private $faq_content_filter_service;
368
+
369
+    /**
370
+     * A {@link Wordlift_Key_Validation_Service} instance.
371
+     *
372
+     * @since  3.9.0
373
+     * @access private
374
+     * @var Wordlift_Key_Validation_Service $key_validation_service A {@link Wordlift_Key_Validation_Service} instance.
375
+     */
376
+    private $key_validation_service;
377
+
378
+    /**
379
+     * A {@link Wordlift_Rating_Service} instance.
380
+     *
381
+     * @since  3.10.0
382
+     * @access private
383
+     * @var \Wordlift_Rating_Service $rating_service A {@link Wordlift_Rating_Service} instance.
384
+     */
385
+    private $rating_service;
386
+
387
+    /**
388
+     * A {@link Wordlift_Post_To_Jsonld_Converter} instance.
389
+     *
390
+     * @since  3.10.0
391
+     * @access protected
392
+     * @var \Wordlift_Post_To_Jsonld_Converter $post_to_jsonld_converter A {@link Wordlift_Post_To_Jsonld_Converter} instance.
393
+     */
394
+    protected $post_to_jsonld_converter;
395
+
396
+    /**
397
+     * A {@link Wordlift_Configuration_Service} instance.
398
+     *
399
+     * @since  3.10.0
400
+     * @access protected
401
+     * @var \Wordlift_Configuration_Service $configuration_service A {@link Wordlift_Configuration_Service} instance.
402
+     */
403
+    protected $configuration_service;
404
+
405
+    /**
406
+     * A {@link Wordlift_Install_Service} instance.
407
+     *
408
+     * @since  3.18.0
409
+     * @access protected
410
+     * @var \Wordlift_Install_Service $install_service A {@link Wordlift_Install_Service} instance.
411
+     */
412
+    protected $install_service;
413
+
414
+    /**
415
+     * A {@link Wordlift_Entity_Type_Service} instance.
416
+     *
417
+     * @since  3.10.0
418
+     * @access protected
419
+     * @var \Wordlift_Entity_Type_Service $entity_type_service A {@link Wordlift_Entity_Type_Service} instance.
420
+     */
421
+    protected $entity_type_service;
422
+
423
+    /**
424
+     * A {@link Wordlift_Entity_Post_To_Jsonld_Converter} instance.
425
+     *
426
+     * @since  3.10.0
427
+     * @access protected
428
+     * @var \Wordlift_Entity_Post_To_Jsonld_Converter $entity_post_to_jsonld_converter A {@link Wordlift_Entity_Post_To_Jsonld_Converter} instance.
429
+     */
430
+    protected $entity_post_to_jsonld_converter;
431
+
432
+    /**
433
+     * A {@link Wordlift_Postid_To_Jsonld_Converter} instance.
434
+     *
435
+     * @since  3.10.0
436
+     * @access protected
437
+     * @var \Wordlift_Postid_To_Jsonld_Converter $postid_to_jsonld_converter A {@link Wordlift_Postid_To_Jsonld_Converter} instance.
438
+     */
439
+    protected $postid_to_jsonld_converter;
440
+
441
+    /**
442
+     * The {@link Wordlift_Admin_Status_Page} class.
443
+     *
444
+     * @since  3.9.8
445
+     * @access private
446
+     * @var \Wordlift_Admin_Status_Page $status_page The {@link Wordlift_Admin_Status_Page} class.
447
+     */
448
+    private $status_page;
449
+
450
+    /**
451
+     * The {@link Wordlift_Category_Taxonomy_Service} instance.
452
+     *
453
+     * @since  3.11.0
454
+     * @access protected
455
+     * @var \Wordlift_Category_Taxonomy_Service $category_taxonomy_service The {@link Wordlift_Category_Taxonomy_Service} instance.
456
+     */
457
+    protected $category_taxonomy_service;
458
+
459
+    /**
460
+     * The {@link Wordlift_Entity_Page_Service} instance.
461
+     *
462
+     * @since  3.11.0
463
+     * @access protected
464
+     * @var \Wordlift_Entity_Page_Service $entity_page_service The {@link Wordlift_Entity_Page_Service} instance.
465
+     */
466
+    protected $entity_page_service;
467
+
468
+    /**
469
+     * The {@link Wordlift_Admin_Settings_Page_Action_Link} class.
470
+     *
471
+     * @since  3.11.0
472
+     * @access protected
473
+     * @var \Wordlift_Admin_Settings_Page_Action_Link $settings_page_action_link The {@link Wordlift_Admin_Settings_Page_Action_Link} class.
474
+     */
475
+    protected $settings_page_action_link;
476
+
477
+    /**
478
+     * The {@link Wordlift_Admin_Settings_Page_Action_Link} class.
479
+     *
480
+     * @since  3.11.0
481
+     * @access protected
482
+     * @var \Wordlift_Admin_Settings_Page_Action_Link $settings_page_action_link The {@link Wordlift_Admin_Settings_Page_Action_Link} class.
483
+     */
484
+    protected $analytics_settings_page_action_link;
485
+
486
+    /**
487
+     * The {@link Wordlift_Analytics_Connect} class.
488
+     *
489
+     * @since  3.11.0
490
+     * @access protected
491
+     * @var \Wordlift_Analytics_Connect $analytics_connect The {@link Wordlift_Analytics_Connect} class.
492
+     */
493
+    protected $analytics_connect;
494
+
495
+    /**
496
+     * The {@link Wordlift_Publisher_Ajax_Adapter} instance.
497
+     *
498
+     * @since  3.11.0
499
+     * @access protected
500
+     * @var \Wordlift_Publisher_Ajax_Adapter $publisher_ajax_adapter The {@link Wordlift_Publisher_Ajax_Adapter} instance.
501
+     */
502
+    protected $publisher_ajax_adapter;
503
+
504
+    /**
505
+     * The {@link Wordlift_Admin_Input_Element} element renderer.
506
+     *
507
+     * @since  3.11.0
508
+     * @access protected
509
+     * @var \Wordlift_Admin_Input_Element $input_element The {@link Wordlift_Admin_Input_Element} element renderer.
510
+     */
511
+    protected $input_element;
512
+
513
+    /**
514
+     * The {@link Wordlift_Admin_Radio_Input_Element} element renderer.
515
+     *
516
+     * @since  3.13.0
517
+     * @access protected
518
+     * @var \Wordlift_Admin_Radio_Input_Element $radio_input_element The {@link Wordlift_Admin_Radio_Input_Element} element renderer.
519
+     */
520
+    protected $radio_input_element;
521
+
522
+    /**
523
+     * The {@link Wordlift_Admin_Language_Select_Element} element renderer.
524
+     *
525
+     * @since  3.11.0
526
+     * @access protected
527
+     * @var \Wordlift_Admin_Language_Select_Element $language_select_element The {@link Wordlift_Admin_Language_Select_Element} element renderer.
528
+     */
529
+    protected $language_select_element;
530
+
531
+    /**
532
+     * The {@link Wordlift_Admin_Country_Select_Element} element renderer.
533
+     *
534
+     * @since  3.18.0
535
+     * @access protected
536
+     * @var \Wordlift_Admin_Country_Select_Element $country_select_element The {@link Wordlift_Admin_Country_Select_Element} element renderer.
537
+     */
538
+    protected $country_select_element;
539
+
540
+    /**
541
+     * The {@link Wordlift_Admin_Publisher_Element} element renderer.
542
+     *
543
+     * @since  3.11.0
544
+     * @access protected
545
+     * @var \Wordlift_Admin_Publisher_Element $publisher_element The {@link Wordlift_Admin_Publisher_Element} element renderer.
546
+     */
547
+    protected $publisher_element;
548
+
549
+    /**
550
+     * The {@link Wordlift_Admin_Select2_Element} element renderer.
551
+     *
552
+     * @since  3.11.0
553
+     * @access protected
554
+     * @var \Wordlift_Admin_Select2_Element $select2_element The {@link Wordlift_Admin_Select2_Element} element renderer.
555
+     */
556
+    protected $select2_element;
557
+
558
+    /**
559
+     * The controller for the entity type list admin page
560
+     *
561
+     * @since  3.11.0
562
+     * @access private
563
+     * @var \Wordlift_Admin_Entity_Taxonomy_List_Page $entity_type_admin_page The {@link Wordlift_Admin_Entity_Taxonomy_List_Page} class.
564
+     */
565
+    private $entity_type_admin_page;
566
+
567
+    /**
568
+     * The controller for the entity type settings admin page
569
+     *
570
+     * @since  3.11.0
571
+     * @access private
572
+     * @var \Wordlift_Admin_Entity_Type_Settings $entity_type_settings_admin_page The {@link Wordlift_Admin_Entity_Type_Settings} class.
573
+     */
574
+    private $entity_type_settings_admin_page;
575
+
576
+    /**
577
+     * The {@link Wordlift_Related_Entities_Cloud_Widget} instance.
578
+     *
579
+     * @since  3.11.0
580
+     * @access protected
581
+     * @var \Wordlift_Related_Entities_Cloud_Widget $related_entities_cloud_widget The {@link Wordlift_Related_Entities_Cloud_Widget} instance.
582
+     */
583
+    protected $related_entities_cloud_widget;
584
+
585
+    /**
586
+     * The {@link Wordlift_Admin_Author_Element} instance.
587
+     *
588
+     * @since  3.14.0
589
+     * @access protected
590
+     * @var \Wordlift_Admin_Author_Element $author_element The {@link Wordlift_Admin_Author_Element} instance.
591
+     */
592
+    protected $author_element;
593
+
594
+    /**
595
+     * The {@link Wordlift_Sample_Data_Service} instance.
596
+     *
597
+     * @since  3.12.0
598
+     * @access protected
599
+     * @var \Wordlift_Sample_Data_Service $sample_data_service The {@link Wordlift_Sample_Data_Service} instance.
600
+     */
601
+    protected $sample_data_service;
602
+
603
+    /**
604
+     * The {@link Wordlift_Sample_Data_Ajax_Adapter} instance.
605
+     *
606
+     * @since  3.12.0
607
+     * @access protected
608
+     * @var \Wordlift_Sample_Data_Ajax_Adapter $sample_data_ajax_adapter The {@link Wordlift_Sample_Data_Ajax_Adapter} instance.
609
+     */
610
+    protected $sample_data_ajax_adapter;
611
+
612
+    /**
613
+     * The {@link Wordlift_Relation_Rebuild_Service} instance.
614
+     *
615
+     * @since  3.14.3
616
+     * @access private
617
+     * @var \Wordlift_Relation_Rebuild_Service $relation_rebuild_service The {@link Wordlift_Relation_Rebuild_Service} instance.
618
+     */
619
+    private $relation_rebuild_service;
620
+
621
+    /**
622
+     * The {@link Wordlift_Relation_Rebuild_Adapter} instance.
623
+     *
624
+     * @since  3.14.3
625
+     * @access private
626
+     * @var \Wordlift_Relation_Rebuild_Adapter $relation_rebuild_adapter The {@link Wordlift_Relation_Rebuild_Adapter} instance.
627
+     */
628
+    private $relation_rebuild_adapter;
629
+
630
+    /**
631
+     * The {@link Wordlift_Reference_Rebuild_Service} instance.
632
+     *
633
+     * @since  3.18.0
634
+     * @access private
635
+     * @var \Wordlift_Reference_Rebuild_Service $reference_rebuild_service The {@link Wordlift_Reference_Rebuild_Service} instance.
636
+     */
637
+    private $reference_rebuild_service;
638
+
639
+    /**
640
+     * The {@link Wordlift_Google_Analytics_Export_Service} instance.
641
+     *
642
+     * @since  3.16.0
643
+     * @access protected
644
+     * @var \Wordlift_Google_Analytics_Export_Service $google_analytics_export_service The {@link Wordlift_Google_Analytics_Export_Service} instance.
645
+     */
646
+    protected $google_analytics_export_service;
647
+
648
+    /**
649
+     * {@link Wordlift}'s singleton instance.
650
+     *
651
+     * @since  3.15.0
652
+     * @access protected
653
+     * @var \Wordlift_Entity_Type_Adapter $entity_type_adapter The {@link Wordlift_Entity_Type_Adapter} instance.
654
+     */
655
+    protected $entity_type_adapter;
656
+
657
+    /**
658
+     * The {@link Wordlift_Storage_Factory} instance.
659
+     *
660
+     * @since  3.15.0
661
+     * @access protected
662
+     * @var \Wordlift_Storage_Factory $storage_factory The {@link Wordlift_Storage_Factory} instance.
663
+     */
664
+    protected $storage_factory;
665
+
666
+    /**
667
+     * The {@link Wordlift_Sparql_Tuple_Rendition_Factory} instance.
668
+     *
669
+     * @since  3.15.0
670
+     * @access protected
671
+     * @var \Wordlift_Sparql_Tuple_Rendition_Factory $rendition_factory The {@link Wordlift_Sparql_Tuple_Rendition_Factory} instance.
672
+     */
673
+    protected $rendition_factory;
674
+
675
+    /**
676
+     * The {@link Wordlift_Autocomplete_Adapter} instance.
677
+     *
678
+     * @since  3.15.0
679
+     * @access private
680
+     * @var \Wordlift_Autocomplete_Adapter $autocomplete_adapter The {@link Wordlift_Autocomplete_Adapter} instance.
681
+     */
682
+    private $autocomplete_adapter;
683
+
684
+    /**
685
+     * The {@link Wordlift_Relation_Service} instance.
686
+     *
687
+     * @since  3.15.0
688
+     * @access protected
689
+     * @var \Wordlift_Relation_Service $relation_service The {@link Wordlift_Relation_Service} instance.
690
+     */
691
+    protected $relation_service;
692
+
693
+    /**
694
+     * The {@link Wordlift_Cached_Post_Converter} instance.
695
+     *
696
+     * @since  3.16.0
697
+     * @access protected
698
+     * @var  \Wordlift_Cached_Post_Converter $cached_postid_to_jsonld_converter The {@link Wordlift_Cached_Post_Converter} instance.
699
+     *
700
+     */
701
+    protected $cached_postid_to_jsonld_converter;
702
+
703
+    /**
704
+     * The {@link Wordlift_Entity_Uri_Service} instance.
705
+     *
706
+     * @since  3.16.3
707
+     * @access protected
708
+     * @var \Wordlift_Entity_Uri_Service $entity_uri_service The {@link Wordlift_Entity_Uri_Service} instance.
709
+     */
710
+    protected $entity_uri_service;
711
+
712
+    /**
713
+     * The {@link Wordlift_Publisher_Service} instance.
714
+     *
715
+     * @since  3.19.0
716
+     * @access protected
717
+     * @var \Wordlift_Publisher_Service $publisher_service The {@link Wordlift_Publisher_Service} instance.
718
+     */
719
+    protected $publisher_service;
720
+
721
+    /**
722
+     * The {@link Wordlift_Context_Cards_Service} instance.
723
+     *
724
+     * @var \Wordlift_Context_Cards_Service The {@link Wordlift_Context_Cards_Service} instance.
725
+     */
726
+    protected $context_cards_service;
727
+
728
+    /**
729
+     * {@link Wordlift}'s singleton instance.
730
+     *
731
+     * @since  3.11.2
732
+     * @access private
733
+     * @var Wordlift $instance {@link Wordlift}'s singleton instance.
734
+     */
735
+    private static $instance;
736
+
737
+    //</editor-fold>
738
+
739
+    /**
740
+     * Define the core functionality of the plugin.
741
+     *
742
+     * Set the plugin name and the plugin version that can be used throughout the plugin.
743
+     * Load the dependencies, define the locale, and set the hooks for the admin area and
744
+     * the public-facing side of the site.
745
+     *
746
+     * @since    1.0.0
747
+     */
748
+    public function __construct() {
749
+
750
+        self::$instance = $this;
751
+
752
+        $this->plugin_name = 'wordlift';
753
+        $this->version     = '3.27.7.2';
754
+        $this->load_dependencies();
755
+        $this->set_locale();
756
+        $this->define_admin_hooks();
757
+        $this->define_public_hooks();
758
+
759
+        // If we're in `WP_CLI` load the related files.
760
+        if ( class_exists( 'WP_CLI' ) ) {
761
+            $this->load_cli_dependencies();
762
+        }
763
+
764
+    }
765
+
766
+    /**
767
+     * Get the singleton instance.
768
+     *
769
+     * @return Wordlift The {@link Wordlift} singleton instance.
770
+     * @since 3.11.2
771
+     *
772
+     */
773
+    public static function get_instance() {
774
+
775
+        return self::$instance;
776
+    }
777
+
778
+    /**
779
+     * Load the required dependencies for this plugin.
780
+     *
781
+     * Include the following files that make up the plugin:
782
+     *
783
+     * - Wordlift_Loader. Orchestrates the hooks of the plugin.
784
+     * - Wordlift_i18n. Defines internationalization functionality.
785
+     * - Wordlift_Admin. Defines all hooks for the admin area.
786
+     * - Wordlift_Public. Defines all hooks for the public side of the site.
787
+     *
788
+     * Create an instance of the loader which will be used to register the hooks
789
+     * with WordPress.
790
+     *
791
+     * @throws Exception
792
+     * @since    1.0.0
793
+     * @access   private
794
+     */
795
+    private function load_dependencies() {
796
+
797
+        /**
798
+         * The class responsible for orchestrating the actions and filters of the
799
+         * core plugin.
800
+         */
801
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-loader.php';
802
+
803
+        // The class responsible for plugin uninstall.
804
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-deactivator-feedback.php';
805
+
806
+        /**
807
+         * The class responsible for defining internationalization functionality
808
+         * of the plugin.
809
+         */
810
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-i18n.php';
811
+
812
+        /**
813
+         * WordLift's supported languages.
814
+         */
815
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-languages.php';
816
+
817
+        /**
818
+         * WordLift's supported countries.
819
+         */
820
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-countries.php';
821
+
822
+        /**
823
+         * Provide support functions to sanitize data.
824
+         */
825
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-sanitizer.php';
826
+
827
+        /** Services. */
828
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-log-service.php';
829
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-http-api.php';
830
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-redirect-service.php';
831
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-configuration-service.php';
832
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-entity-post-type-service.php';
833
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-entity-type-service.php';
834
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-entity-link-service.php';
835
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-linked-data-service.php';
836
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-relation-service.php';
837
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-image-service.php';
838
+
839
+        /**
840
+         * The Query builder.
841
+         */
842
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-query-builder.php';
843
+
844
+        /**
845
+         * The Schema service.
846
+         */
847
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-schema-service.php';
848
+
849
+        /**
850
+         * The schema:url property service.
851
+         */
852
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-property-service.php';
853
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-schema-url-property-service.php';
854
+
855
+        /**
856
+         * The UI service.
857
+         */
858
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-ui-service.php';
859
+
860
+        /**
861
+         * The Thumbnail service.
862
+         */
863
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-thumbnail-service.php';
864
+
865
+        /**
866
+         * The Entity Types Taxonomy service.
867
+         */
868
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-entity-type-taxonomy-service.php';
869
+
870
+        /**
871
+         * The Entity service.
872
+         */
873
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-entity-uri-service.php';
874
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-entity-service.php';
875
+
876
+        // Add the entity rating service.
877
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-rating-service.php';
878
+
879
+        /**
880
+         * The User service.
881
+         */
882
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-user-service.php';
883
+
884
+        /**
885
+         * The Timeline service.
886
+         */
887
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-timeline-service.php';
888
+
889
+        /**
890
+         * The Topic Taxonomy service.
891
+         */
892
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-topic-taxonomy-service.php';
893
+
894
+        /**
895
+         * The SPARQL service.
896
+         */
897
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-sparql-service.php';
898
+
899
+        /**
900
+         * The WordLift import service.
901
+         */
902
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-import-service.php';
903
+
904
+        /**
905
+         * The WordLift URI service.
906
+         */
907
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-uri-service.php';
908
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-property-factory.php';
909
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-sample-data-service.php';
910
+
911
+        /**
912
+         * The WordLift rebuild service, used to rebuild the remote dataset using the local data.
913
+         */
914
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/rebuild/class-wordlift-listable.php';
915
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/rebuild/class-wordlift-rebuild-service.php';
916
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/rebuild/class-wordlift-reference-rebuild-service.php';
917
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/rebuild/class-wordlift-relation-rebuild-service.php';
918
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/rebuild/class-wordlift-relation-rebuild-adapter.php';
919
+
920
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/properties/class-wordlift-property-getter-factory.php';
921
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-attachment-service.php';
922
+
923
+        /**
924
+         * Load the converters.
925
+         */
926
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/intf-wordlift-post-converter.php';
927
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-abstract-post-to-jsonld-converter.php';
928
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-postid-to-jsonld-converter.php';
929
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-entity-post-to-jsonld-converter.php';
930
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-post-to-jsonld-converter.php';
931
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-jsonld-website-converter.php';
932
+
933
+        /**
934
+         * Load cache-related files.
935
+         */
936
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/cache/require.php';
937
+
938
+        /**
939
+         * Load the content filter.
940
+         */
941
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-content-filter-service.php';
942
+
943
+        /*
944 944
 		 * Load the excerpt helper.
945 945
 		 */
946
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-post-excerpt-helper.php';
947
-
948
-		/**
949
-		 * Load the JSON-LD service to publish entities using JSON-LD.s
950
-		 *
951
-		 * @since 3.8.0
952
-		 */
953
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-jsonld-service.php';
954
-
955
-		// The Publisher Service and the AJAX adapter.
956
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-publisher-service.php';
957
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-publisher-ajax-adapter.php';
958
-
959
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-post-adapter.php';
960
-
961
-		/**
962
-		 * Load the WordLift key validation service.
963
-		 */
964
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-key-validation-service.php';
965
-
966
-		// Load the `Wordlift_Category_Taxonomy_Service` class definition.
967
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-category-taxonomy-service.php';
968
-
969
-		// Load the `Wordlift_Entity_Page_Service` class definition.
970
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-entity-page-service.php';
971
-
972
-		/** Linked Data. */
973
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-storage.php';
974
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-post-meta-storage.php';
975
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-post-property-storage.php';
976
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-post-taxonomy-storage.php';
977
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-post-schema-class-storage.php';
978
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-post-author-storage.php';
979
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-post-meta-uri-storage.php';
980
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-post-image-storage.php';
981
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-post-related-storage.php';
982
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-url-property-storage.php';
983
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-storage-factory.php';
984
-
985
-		/** Linked Data Rendition. */
986
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/rendition/intf-wordlift-sparql-tuple-rendition.php';
987
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/rendition/class-wordlift-default-sparql-tuple-rendition.php';
988
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/rendition/class-wordlift-address-sparql-tuple-rendition.php';
989
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/rendition/class-wordlift-sparql-tuple-rendition-factory.php';
990
-
991
-		/** Services. */
992
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-google-analytics-export-service.php';
993
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-api-service.php';
994
-
995
-		/** Adapters. */
996
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-tinymce-adapter.php';
997
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-newrelic-adapter.php';
998
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-sample-data-ajax-adapter.php';
999
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-entity-type-adapter.php';
1000
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-wprocket-adapter.php';
1001
-
1002
-		/** Async Tasks. */
1003
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/wp-async-task/class-wordlift-async-task.php';
1004
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/wp-async-task/class-wordlift-sparql-query-async-task.php';
1005
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/wp-async-task/class-wordlift-push-references-async-task.php';
1006
-
1007
-		/** Autocomplete. */
1008
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-autocomplete-adapter.php';
1009
-
1010
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-remote-image-service.php';
1011
-
1012
-		/** Analytics */
1013
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/analytics/class-wordlift-analytics-connect.php';
1014
-
1015
-		/**
1016
-		 * The class responsible for defining all actions that occur in the admin area.
1017
-		 */
1018
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin.php';
1019
-
1020
-		/**
1021
-		 * The class to customize the entity list admin page.
1022
-		 */
1023
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-entity-list.php';
1024
-
1025
-		/**
1026
-		 * The Entity Types Taxonomy Walker (transforms checkboxes into radios).
1027
-		 */
1028
-		global $wp_version;
1029
-		if ( version_compare( $wp_version, '5.3', '<' ) ) {
1030
-			require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-entity-types-taxonomy-walker.php';
1031
-		} else {
1032
-			require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-entity-types-taxonomy-walker-5-3.php';
1033
-		}
1034
-
1035
-		/**
1036
-		 * The Notice service.
1037
-		 */
1038
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-notice-service.php';
1039
-
1040
-		/**
1041
-		 * The PrimaShop adapter.
1042
-		 */
1043
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-primashop-adapter.php';
1044
-
1045
-		/**
1046
-		 * The WordLift Dashboard service.
1047
-		 */
1048
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-dashboard.php';
1049
-
1050
-		/**
1051
-		 * The admin 'Install wizard' page.
1052
-		 */
1053
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-setup.php';
1054
-
1055
-		/**
1056
-		 * The WordLift entity type list admin page controller.
1057
-		 */
1058
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-entity-taxonomy-list-page.php';
1059
-
1060
-		/**
1061
-		 * The WordLift entity type settings admin page controller.
1062
-		 */
1063
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-entity-type-settings.php';
1064
-
1065
-		/**
1066
-		 * The admin 'Download Your Data' page.
1067
-		 */
1068
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-download-your-data-page.php';
1069
-
1070
-		/**
1071
-		 * The admin 'WordLift Settings' page.
1072
-		 */
1073
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/elements/intf-wordlift-admin-element.php';
1074
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/elements/class-wordlift-admin-input-element.php';
1075
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/elements/class-wordlift-admin-input-radio-element.php';
1076
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/elements/class-wordlift-admin-select-element.php';
1077
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/elements/class-wordlift-admin-select2-element.php';
1078
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/elements/class-wordlift-admin-language-select-element.php';
1079
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/elements/class-wordlift-admin-country-select-element.php';
1080
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/elements/class-wordlift-admin-tabs-element.php';
1081
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/elements/class-wordlift-admin-author-element.php';
1082
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/elements/class-wordlift-admin-publisher-element.php';
1083
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-page.php';
1084
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-settings-page.php';
1085
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-settings-analytics-page.php';
1086
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-settings-page-action-link.php';
1087
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-settings-analytics-page-action-link.php';
1088
-
1089
-		/** Admin Pages */
1090
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-user-profile-page.php';
1091
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-status-page.php';
1092
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-search-rankings-page.php';
1093
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-entity-type-admin-service.php';
1094
-
1095
-		/**
1096
-		 * The class responsible for defining all actions that occur in the public-facing
1097
-		 * side of the site.
1098
-		 */
1099
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-public.php';
1100
-
1101
-		/**
1102
-		 * The shortcode abstract class.
1103
-		 */
1104
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-shortcode.php';
1105
-
1106
-		/**
1107
-		 * The Timeline shortcode.
1108
-		 */
1109
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-timeline-shortcode.php';
1110
-
1111
-		/**
1112
-		 * The Navigator shortcode.
1113
-		 */
1114
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-navigator-shortcode.php';
1115
-
1116
-		/**
1117
-		 * The Products Navigator shortcode.
1118
-		 */
1119
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-products-navigator-shortcode.php';
1120
-
1121
-		/**
1122
-		 * The chord shortcode.
1123
-		 */
1124
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-chord-shortcode.php';
1125
-
1126
-		/**
1127
-		 * The geomap shortcode.
1128
-		 */
1129
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-geomap-shortcode.php';
1130
-
1131
-		/**
1132
-		 * The entity cloud shortcode.
1133
-		 */
1134
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-related-entities-cloud-shortcode.php';
1135
-
1136
-		/**
1137
-		 * The entity glossary shortcode.
1138
-		 */
1139
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-alphabet-service.php';
1140
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-vocabulary-shortcode.php';
1141
-
1142
-		/**
1143
-		 * Faceted Search shortcode.
1144
-		 */
1145
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-faceted-search-shortcode.php';
1146
-
1147
-		/**
1148
-		 * The ShareThis service.
1149
-		 */
1150
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-sharethis-service.php';
1151
-
1152
-		/**
1153
-		 * The SEO service.
1154
-		 */
1155
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-seo-service.php';
1156
-
1157
-		/**
1158
-		 * The AMP service.
1159
-		 */
1160
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-amp-service.php';
1161
-
1162
-		/** Widgets */
1163
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-widget.php';
1164
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-related-entities-cloud-widget.php';
1165
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-context-cards.php';
1166
-
1167
-		/*
946
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-post-excerpt-helper.php';
947
+
948
+        /**
949
+         * Load the JSON-LD service to publish entities using JSON-LD.s
950
+         *
951
+         * @since 3.8.0
952
+         */
953
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-jsonld-service.php';
954
+
955
+        // The Publisher Service and the AJAX adapter.
956
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-publisher-service.php';
957
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-publisher-ajax-adapter.php';
958
+
959
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-post-adapter.php';
960
+
961
+        /**
962
+         * Load the WordLift key validation service.
963
+         */
964
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-key-validation-service.php';
965
+
966
+        // Load the `Wordlift_Category_Taxonomy_Service` class definition.
967
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-category-taxonomy-service.php';
968
+
969
+        // Load the `Wordlift_Entity_Page_Service` class definition.
970
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-entity-page-service.php';
971
+
972
+        /** Linked Data. */
973
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-storage.php';
974
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-post-meta-storage.php';
975
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-post-property-storage.php';
976
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-post-taxonomy-storage.php';
977
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-post-schema-class-storage.php';
978
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-post-author-storage.php';
979
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-post-meta-uri-storage.php';
980
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-post-image-storage.php';
981
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-post-related-storage.php';
982
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-url-property-storage.php';
983
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-storage-factory.php';
984
+
985
+        /** Linked Data Rendition. */
986
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/rendition/intf-wordlift-sparql-tuple-rendition.php';
987
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/rendition/class-wordlift-default-sparql-tuple-rendition.php';
988
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/rendition/class-wordlift-address-sparql-tuple-rendition.php';
989
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/rendition/class-wordlift-sparql-tuple-rendition-factory.php';
990
+
991
+        /** Services. */
992
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-google-analytics-export-service.php';
993
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-api-service.php';
994
+
995
+        /** Adapters. */
996
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-tinymce-adapter.php';
997
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-newrelic-adapter.php';
998
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-sample-data-ajax-adapter.php';
999
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-entity-type-adapter.php';
1000
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-wprocket-adapter.php';
1001
+
1002
+        /** Async Tasks. */
1003
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/wp-async-task/class-wordlift-async-task.php';
1004
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/wp-async-task/class-wordlift-sparql-query-async-task.php';
1005
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/wp-async-task/class-wordlift-push-references-async-task.php';
1006
+
1007
+        /** Autocomplete. */
1008
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-autocomplete-adapter.php';
1009
+
1010
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-remote-image-service.php';
1011
+
1012
+        /** Analytics */
1013
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/analytics/class-wordlift-analytics-connect.php';
1014
+
1015
+        /**
1016
+         * The class responsible for defining all actions that occur in the admin area.
1017
+         */
1018
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin.php';
1019
+
1020
+        /**
1021
+         * The class to customize the entity list admin page.
1022
+         */
1023
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-entity-list.php';
1024
+
1025
+        /**
1026
+         * The Entity Types Taxonomy Walker (transforms checkboxes into radios).
1027
+         */
1028
+        global $wp_version;
1029
+        if ( version_compare( $wp_version, '5.3', '<' ) ) {
1030
+            require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-entity-types-taxonomy-walker.php';
1031
+        } else {
1032
+            require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-entity-types-taxonomy-walker-5-3.php';
1033
+        }
1034
+
1035
+        /**
1036
+         * The Notice service.
1037
+         */
1038
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-notice-service.php';
1039
+
1040
+        /**
1041
+         * The PrimaShop adapter.
1042
+         */
1043
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-primashop-adapter.php';
1044
+
1045
+        /**
1046
+         * The WordLift Dashboard service.
1047
+         */
1048
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-dashboard.php';
1049
+
1050
+        /**
1051
+         * The admin 'Install wizard' page.
1052
+         */
1053
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-setup.php';
1054
+
1055
+        /**
1056
+         * The WordLift entity type list admin page controller.
1057
+         */
1058
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-entity-taxonomy-list-page.php';
1059
+
1060
+        /**
1061
+         * The WordLift entity type settings admin page controller.
1062
+         */
1063
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-entity-type-settings.php';
1064
+
1065
+        /**
1066
+         * The admin 'Download Your Data' page.
1067
+         */
1068
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-download-your-data-page.php';
1069
+
1070
+        /**
1071
+         * The admin 'WordLift Settings' page.
1072
+         */
1073
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/elements/intf-wordlift-admin-element.php';
1074
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/elements/class-wordlift-admin-input-element.php';
1075
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/elements/class-wordlift-admin-input-radio-element.php';
1076
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/elements/class-wordlift-admin-select-element.php';
1077
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/elements/class-wordlift-admin-select2-element.php';
1078
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/elements/class-wordlift-admin-language-select-element.php';
1079
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/elements/class-wordlift-admin-country-select-element.php';
1080
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/elements/class-wordlift-admin-tabs-element.php';
1081
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/elements/class-wordlift-admin-author-element.php';
1082
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/elements/class-wordlift-admin-publisher-element.php';
1083
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-page.php';
1084
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-settings-page.php';
1085
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-settings-analytics-page.php';
1086
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-settings-page-action-link.php';
1087
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-settings-analytics-page-action-link.php';
1088
+
1089
+        /** Admin Pages */
1090
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-user-profile-page.php';
1091
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-status-page.php';
1092
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-search-rankings-page.php';
1093
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-entity-type-admin-service.php';
1094
+
1095
+        /**
1096
+         * The class responsible for defining all actions that occur in the public-facing
1097
+         * side of the site.
1098
+         */
1099
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-public.php';
1100
+
1101
+        /**
1102
+         * The shortcode abstract class.
1103
+         */
1104
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-shortcode.php';
1105
+
1106
+        /**
1107
+         * The Timeline shortcode.
1108
+         */
1109
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-timeline-shortcode.php';
1110
+
1111
+        /**
1112
+         * The Navigator shortcode.
1113
+         */
1114
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-navigator-shortcode.php';
1115
+
1116
+        /**
1117
+         * The Products Navigator shortcode.
1118
+         */
1119
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-products-navigator-shortcode.php';
1120
+
1121
+        /**
1122
+         * The chord shortcode.
1123
+         */
1124
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-chord-shortcode.php';
1125
+
1126
+        /**
1127
+         * The geomap shortcode.
1128
+         */
1129
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-geomap-shortcode.php';
1130
+
1131
+        /**
1132
+         * The entity cloud shortcode.
1133
+         */
1134
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-related-entities-cloud-shortcode.php';
1135
+
1136
+        /**
1137
+         * The entity glossary shortcode.
1138
+         */
1139
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-alphabet-service.php';
1140
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-vocabulary-shortcode.php';
1141
+
1142
+        /**
1143
+         * Faceted Search shortcode.
1144
+         */
1145
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-faceted-search-shortcode.php';
1146
+
1147
+        /**
1148
+         * The ShareThis service.
1149
+         */
1150
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-sharethis-service.php';
1151
+
1152
+        /**
1153
+         * The SEO service.
1154
+         */
1155
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-seo-service.php';
1156
+
1157
+        /**
1158
+         * The AMP service.
1159
+         */
1160
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-amp-service.php';
1161
+
1162
+        /** Widgets */
1163
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-widget.php';
1164
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-related-entities-cloud-widget.php';
1165
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-context-cards.php';
1166
+
1167
+        /*
1168 1168
 		 * Schema.org Services.
1169 1169
 		 *
1170 1170
 		 * @see https://github.com/insideout10/wordlift-plugin/issues/835
1171 1171
 		 */
1172
-		if ( WL_ALL_ENTITY_TYPES ) {
1173
-			require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/schemaorg/class-wordlift-schemaorg-sync-service.php';
1174
-			require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/schemaorg/class-wordlift-schemaorg-property-service.php';
1175
-			require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/schemaorg/class-wordlift-schemaorg-class-service.php';
1176
-			new Wordlift_Schemaorg_Sync_Service();
1177
-			$schemaorg_property_service = new Wordlift_Schemaorg_Property_Service();
1178
-			new Wordlift_Schemaorg_Class_Service();
1179
-		} else {
1180
-			$schemaorg_property_service = null;
1181
-		}
1172
+        if ( WL_ALL_ENTITY_TYPES ) {
1173
+            require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/schemaorg/class-wordlift-schemaorg-sync-service.php';
1174
+            require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/schemaorg/class-wordlift-schemaorg-property-service.php';
1175
+            require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/schemaorg/class-wordlift-schemaorg-class-service.php';
1176
+            new Wordlift_Schemaorg_Sync_Service();
1177
+            $schemaorg_property_service = new Wordlift_Schemaorg_Property_Service();
1178
+            new Wordlift_Schemaorg_Class_Service();
1179
+        } else {
1180
+            $schemaorg_property_service = null;
1181
+        }
1182 1182
 
1183
-		$this->loader = new Wordlift_Loader();
1183
+        $this->loader = new Wordlift_Loader();
1184 1184
 
1185
-		// Instantiate a global logger.
1186
-		global $wl_logger;
1187
-		$wl_logger = Wordlift_Log_Service::get_logger( 'WordLift' );
1185
+        // Instantiate a global logger.
1186
+        global $wl_logger;
1187
+        $wl_logger = Wordlift_Log_Service::get_logger( 'WordLift' );
1188 1188
 
1189
-		// Load the `wl-api` end-point.
1190
-		new Wordlift_Http_Api();
1189
+        // Load the `wl-api` end-point.
1190
+        new Wordlift_Http_Api();
1191 1191
 
1192
-		// Load the Install Service.
1193
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'install/class-wordlift-install-service.php';
1194
-		$this->install_service = new Wordlift_Install_Service();
1192
+        // Load the Install Service.
1193
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'install/class-wordlift-install-service.php';
1194
+        $this->install_service = new Wordlift_Install_Service();
1195 1195
 
1196
-		/** Services. */
1197
-		// Create the configuration service.
1198
-		$this->configuration_service = new Wordlift_Configuration_Service();
1199
-		$api_service                 = new Wordlift_Api_Service( $this->configuration_service );
1196
+        /** Services. */
1197
+        // Create the configuration service.
1198
+        $this->configuration_service = new Wordlift_Configuration_Service();
1199
+        $api_service                 = new Wordlift_Api_Service( $this->configuration_service );
1200 1200
 
1201
-		// Create an entity type service instance. It'll be later bound to the init action.
1202
-		$this->entity_post_type_service = new Wordlift_Entity_Post_Type_Service( Wordlift_Entity_Service::TYPE_NAME, $this->configuration_service->get_entity_base_path() );
1201
+        // Create an entity type service instance. It'll be later bound to the init action.
1202
+        $this->entity_post_type_service = new Wordlift_Entity_Post_Type_Service( Wordlift_Entity_Service::TYPE_NAME, $this->configuration_service->get_entity_base_path() );
1203 1203
 
1204
-		// Create an entity link service instance. It'll be later bound to the post_type_link and pre_get_posts actions.
1205
-		$this->entity_link_service = new Wordlift_Entity_Link_Service( $this->entity_post_type_service, $this->configuration_service->get_entity_base_path() );
1204
+        // Create an entity link service instance. It'll be later bound to the post_type_link and pre_get_posts actions.
1205
+        $this->entity_link_service = new Wordlift_Entity_Link_Service( $this->entity_post_type_service, $this->configuration_service->get_entity_base_path() );
1206 1206
 
1207
-		// Create an instance of the UI service.
1208
-		$this->ui_service = new Wordlift_UI_Service();
1207
+        // Create an instance of the UI service.
1208
+        $this->ui_service = new Wordlift_UI_Service();
1209 1209
 
1210
-		// Create an instance of the Thumbnail service. Later it'll be hooked to post meta events.
1211
-		$this->thumbnail_service = new Wordlift_Thumbnail_Service();
1210
+        // Create an instance of the Thumbnail service. Later it'll be hooked to post meta events.
1211
+        $this->thumbnail_service = new Wordlift_Thumbnail_Service();
1212 1212
 
1213
-		$this->sparql_service        = new Wordlift_Sparql_Service();
1214
-		$schema_url_property_service = new Wordlift_Schema_Url_Property_Service( $this->sparql_service );
1215
-		$this->notice_service        = new Wordlift_Notice_Service();
1216
-		$this->relation_service      = new Wordlift_Relation_Service();
1213
+        $this->sparql_service        = new Wordlift_Sparql_Service();
1214
+        $schema_url_property_service = new Wordlift_Schema_Url_Property_Service( $this->sparql_service );
1215
+        $this->notice_service        = new Wordlift_Notice_Service();
1216
+        $this->relation_service      = new Wordlift_Relation_Service();
1217 1217
 
1218
-		$entity_uri_cache_service = new Wordlift_File_Cache_Service( WL_TEMP_DIR . 'entity_uri/' );
1219
-		$this->entity_uri_service = new Wordlift_Cached_Entity_Uri_Service( $this->configuration_service, $entity_uri_cache_service );
1220
-		$this->entity_service     = new Wordlift_Entity_Service( $this->ui_service, $this->relation_service, $this->entity_uri_service );
1221
-		$this->user_service       = new Wordlift_User_Service( $this->sparql_service, $this->entity_service );
1218
+        $entity_uri_cache_service = new Wordlift_File_Cache_Service( WL_TEMP_DIR . 'entity_uri/' );
1219
+        $this->entity_uri_service = new Wordlift_Cached_Entity_Uri_Service( $this->configuration_service, $entity_uri_cache_service );
1220
+        $this->entity_service     = new Wordlift_Entity_Service( $this->ui_service, $this->relation_service, $this->entity_uri_service );
1221
+        $this->user_service       = new Wordlift_User_Service( $this->sparql_service, $this->entity_service );
1222 1222
 
1223
-		// Instantiate the JSON-LD service.
1224
-		$property_getter = Wordlift_Property_Getter_Factory::create( $this->entity_service );
1223
+        // Instantiate the JSON-LD service.
1224
+        $property_getter = Wordlift_Property_Getter_Factory::create( $this->entity_service );
1225 1225
 
1226
-		/** Linked Data. */
1227
-		$this->storage_factory   = new Wordlift_Storage_Factory( $this->entity_service, $this->user_service, $property_getter );
1228
-		$this->rendition_factory = new Wordlift_Sparql_Tuple_Rendition_Factory( $this->entity_service );
1226
+        /** Linked Data. */
1227
+        $this->storage_factory   = new Wordlift_Storage_Factory( $this->entity_service, $this->user_service, $property_getter );
1228
+        $this->rendition_factory = new Wordlift_Sparql_Tuple_Rendition_Factory( $this->entity_service );
1229 1229
 
1230
-		$this->schema_service = new Wordlift_Schema_Service( $this->storage_factory, $this->rendition_factory, $this->configuration_service );
1230
+        $this->schema_service = new Wordlift_Schema_Service( $this->storage_factory, $this->rendition_factory, $this->configuration_service );
1231 1231
 
1232
-		// Create a new instance of the Redirect service.
1233
-		$this->redirect_service    = new Wordlift_Redirect_Service( $this->entity_uri_service );
1234
-		$this->entity_type_service = new Wordlift_Entity_Type_Service( $this->schema_service );
1232
+        // Create a new instance of the Redirect service.
1233
+        $this->redirect_service    = new Wordlift_Redirect_Service( $this->entity_uri_service );
1234
+        $this->entity_type_service = new Wordlift_Entity_Type_Service( $this->schema_service );
1235 1235
 
1236
-		// Create a new instance of the Timeline service and Timeline shortcode.
1237
-		$this->timeline_service = new Wordlift_Timeline_Service( $this->entity_service, $this->entity_type_service );
1236
+        // Create a new instance of the Timeline service and Timeline shortcode.
1237
+        $this->timeline_service = new Wordlift_Timeline_Service( $this->entity_service, $this->entity_type_service );
1238 1238
 
1239
-		$this->entity_types_taxonomy_walker = new Wordlift_Entity_Types_Taxonomy_Walker();
1239
+        $this->entity_types_taxonomy_walker = new Wordlift_Entity_Types_Taxonomy_Walker();
1240 1240
 
1241
-		$this->topic_taxonomy_service        = new Wordlift_Topic_Taxonomy_Service();
1242
-		$this->entity_types_taxonomy_service = new Wordlift_Entity_Type_Taxonomy_Service();
1241
+        $this->topic_taxonomy_service        = new Wordlift_Topic_Taxonomy_Service();
1242
+        $this->entity_types_taxonomy_service = new Wordlift_Entity_Type_Taxonomy_Service();
1243 1243
 
1244
-		// Create an instance of the ShareThis service, later we hook it to the_content and the_excerpt filters.
1245
-		$this->sharethis_service = new Wordlift_ShareThis_Service();
1244
+        // Create an instance of the ShareThis service, later we hook it to the_content and the_excerpt filters.
1245
+        $this->sharethis_service = new Wordlift_ShareThis_Service();
1246 1246
 
1247
-		// Create an instance of the PrimaShop adapter.
1248
-		$this->primashop_adapter = new Wordlift_PrimaShop_Adapter();
1247
+        // Create an instance of the PrimaShop adapter.
1248
+        $this->primashop_adapter = new Wordlift_PrimaShop_Adapter();
1249 1249
 
1250
-		// Create an import service instance to hook later to WP's import function.
1251
-		$this->import_service = new Wordlift_Import_Service( $this->entity_post_type_service, $this->entity_service, $this->schema_service, $this->sparql_service, $this->configuration_service->get_dataset_uri() );
1250
+        // Create an import service instance to hook later to WP's import function.
1251
+        $this->import_service = new Wordlift_Import_Service( $this->entity_post_type_service, $this->entity_service, $this->schema_service, $this->sparql_service, $this->configuration_service->get_dataset_uri() );
1252 1252
 
1253
-		$uri_service = new Wordlift_Uri_Service( $GLOBALS['wpdb'] );
1253
+        $uri_service = new Wordlift_Uri_Service( $GLOBALS['wpdb'] );
1254 1254
 
1255
-		// Create the entity rating service.
1256
-		$this->rating_service = new Wordlift_Rating_Service( $this->entity_service, $this->entity_type_service, $this->notice_service );
1255
+        // Create the entity rating service.
1256
+        $this->rating_service = new Wordlift_Rating_Service( $this->entity_service, $this->entity_type_service, $this->notice_service );
1257 1257
 
1258
-		// Create entity list customization (wp-admin/edit.php).
1259
-		$this->entity_list_service = new Wordlift_Entity_List_Service( $this->rating_service );
1258
+        // Create entity list customization (wp-admin/edit.php).
1259
+        $this->entity_list_service = new Wordlift_Entity_List_Service( $this->rating_service );
1260 1260
 
1261
-		// Create a new instance of the Redirect service.
1262
-		$this->dashboard_service = new Wordlift_Dashboard_Service( $this->rating_service, $this->entity_service );
1261
+        // Create a new instance of the Redirect service.
1262
+        $this->dashboard_service = new Wordlift_Dashboard_Service( $this->rating_service, $this->entity_service );
1263 1263
 
1264
-		// Create an instance of the Publisher Service and the AJAX Adapter.
1265
-		$this->publisher_service = new Wordlift_Publisher_Service( $this->configuration_service );
1266
-		$this->property_factory  = new Wordlift_Property_Factory( $schema_url_property_service );
1267
-		$this->property_factory->register( Wordlift_Schema_Url_Property_Service::META_KEY, $schema_url_property_service );
1264
+        // Create an instance of the Publisher Service and the AJAX Adapter.
1265
+        $this->publisher_service = new Wordlift_Publisher_Service( $this->configuration_service );
1266
+        $this->property_factory  = new Wordlift_Property_Factory( $schema_url_property_service );
1267
+        $this->property_factory->register( Wordlift_Schema_Url_Property_Service::META_KEY, $schema_url_property_service );
1268 1268
 
1269
-		$attachment_service = new Wordlift_Attachment_Service();
1269
+        $attachment_service = new Wordlift_Attachment_Service();
1270 1270
 
1271
-		// Instantiate the JSON-LD service.
1272
-		$property_getter                       = Wordlift_Property_Getter_Factory::create( $this->entity_service );
1273
-		$this->post_to_jsonld_converter        = new Wordlift_Post_To_Jsonld_Converter( $this->entity_type_service, $this->entity_service, $this->user_service, $attachment_service, $this->configuration_service );
1274
-		$this->entity_post_to_jsonld_converter = new Wordlift_Entity_Post_To_Jsonld_Converter( $this->entity_type_service, $this->entity_service, $this->user_service, $attachment_service, $property_getter, $schemaorg_property_service, $this->post_to_jsonld_converter );
1275
-		$this->postid_to_jsonld_converter      = new Wordlift_Postid_To_Jsonld_Converter( $this->entity_service, $this->entity_post_to_jsonld_converter, $this->post_to_jsonld_converter );
1276
-		$this->jsonld_website_converter        = new Wordlift_Website_Jsonld_Converter( $this->entity_type_service, $this->entity_service, $this->user_service, $attachment_service, $this->configuration_service );
1271
+        // Instantiate the JSON-LD service.
1272
+        $property_getter                       = Wordlift_Property_Getter_Factory::create( $this->entity_service );
1273
+        $this->post_to_jsonld_converter        = new Wordlift_Post_To_Jsonld_Converter( $this->entity_type_service, $this->entity_service, $this->user_service, $attachment_service, $this->configuration_service );
1274
+        $this->entity_post_to_jsonld_converter = new Wordlift_Entity_Post_To_Jsonld_Converter( $this->entity_type_service, $this->entity_service, $this->user_service, $attachment_service, $property_getter, $schemaorg_property_service, $this->post_to_jsonld_converter );
1275
+        $this->postid_to_jsonld_converter      = new Wordlift_Postid_To_Jsonld_Converter( $this->entity_service, $this->entity_post_to_jsonld_converter, $this->post_to_jsonld_converter );
1276
+        $this->jsonld_website_converter        = new Wordlift_Website_Jsonld_Converter( $this->entity_type_service, $this->entity_service, $this->user_service, $attachment_service, $this->configuration_service );
1277 1277
 
1278
-		$jsonld_cache                            = new Ttl_Cache( 'jsonld', 86400 );
1279
-		$this->cached_postid_to_jsonld_converter = new Wordlift_Cached_Post_Converter( $this->postid_to_jsonld_converter, $this->configuration_service, $jsonld_cache );
1280
-		$this->jsonld_service                    = new Wordlift_Jsonld_Service( $this->entity_service, $this->cached_postid_to_jsonld_converter, $this->jsonld_website_converter );
1278
+        $jsonld_cache                            = new Ttl_Cache( 'jsonld', 86400 );
1279
+        $this->cached_postid_to_jsonld_converter = new Wordlift_Cached_Post_Converter( $this->postid_to_jsonld_converter, $this->configuration_service, $jsonld_cache );
1280
+        $this->jsonld_service                    = new Wordlift_Jsonld_Service( $this->entity_service, $this->cached_postid_to_jsonld_converter, $this->jsonld_website_converter );
1281 1281
 
1282
-		/*
1282
+        /*
1283 1283
 		 * Load the `Wordlift_Term_JsonLd_Adapter`.
1284 1284
 		 *
1285 1285
 		 * @see https://github.com/insideout10/wordlift-plugin/issues/892
1286 1286
 		 *
1287 1287
 		 * @since 3.20.0
1288 1288
 		 */
1289
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-term-jsonld-adapter.php';
1290
-		$term_jsonld_adapter = new Wordlift_Term_JsonLd_Adapter( $this->entity_uri_service, $this->jsonld_service );
1291
-		$jsonld_service      = new Jsonld_Service(
1292
-			$this->jsonld_service,
1293
-			$term_jsonld_adapter,
1294
-			new Jsonld_User_Service( $this->user_service ) );
1295
-		new Jsonld_Endpoint( $jsonld_service, $this->entity_uri_service );
1296
-
1297
-		// Prints the JSON-LD in the head.
1298
-		new Jsonld_Adapter( $this->jsonld_service );
1299
-
1300
-		new Jsonld_By_Id_Endpoint( $this->jsonld_service, $this->entity_uri_service );
1301
-
1302
-		$this->key_validation_service = new Wordlift_Key_Validation_Service( $this->configuration_service );
1303
-		$this->content_filter_service = new Wordlift_Content_Filter_Service( $this->entity_service, $this->configuration_service, $this->entity_uri_service );
1304
-		// Creating Faq Content filter service.
1305
-		$this->faq_content_filter_service = new Faq_Content_Filter();
1306
-		$this->relation_rebuild_service   = new Wordlift_Relation_Rebuild_Service( $this->content_filter_service, $this->entity_service );
1307
-		$this->sample_data_service        = new Wordlift_Sample_Data_Service( $this->entity_type_service, $this->configuration_service, $this->user_service );
1308
-		$this->sample_data_ajax_adapter   = new Wordlift_Sample_Data_Ajax_Adapter( $this->sample_data_service );
1309
-		$this->reference_rebuild_service  = new Wordlift_Reference_Rebuild_Service( $this->entity_service );
1310
-
1311
-		$this->loader->add_action( 'enqueue_block_editor_assets', $this, 'add_wl_enabled_blocks' );
1312
-
1313
-		/**
1314
-		 * Filter: wl_feature__enable__blocks.
1315
-		 *
1316
-		 * @param bool whether the blocks needed to be registered, defaults to true.
1317
-		 *
1318
-		 * @return bool
1319
-		 * @since 3.27.6
1320
-		 */
1321
-		if ( apply_filters( 'wl_feature__enable__blocks', true ) ) {
1322
-			// Initialize the short-codes.
1323
-			new Async_Template_Decorator( new Wordlift_Navigator_Shortcode() );
1324
-			new Wordlift_Chord_Shortcode();
1325
-			new Wordlift_Geomap_Shortcode();
1326
-			new Wordlift_Timeline_Shortcode();
1327
-			new Wordlift_Related_Entities_Cloud_Shortcode( $this->relation_service );
1328
-			new Wordlift_Vocabulary_Shortcode( $this->configuration_service );
1329
-			new Async_Template_Decorator( new Wordlift_Faceted_Search_Shortcode() );
1330
-		}
1331
-
1332
-		new Wordlift_Products_Navigator_Shortcode();
1333
-
1334
-
1335
-		// Initialize the Context Cards Service
1336
-		$this->context_cards_service = new Wordlift_Context_Cards_Service();
1337
-
1338
-		// Initialize the SEO service.
1339
-		new Wordlift_Seo_Service();
1340
-
1341
-		// Initialize the AMP service.
1342
-		new Wordlift_AMP_Service( $this->jsonld_service );
1343
-
1344
-		/** Services. */
1345
-		$this->google_analytics_export_service = new Wordlift_Google_Analytics_Export_Service();
1346
-		new Wordlift_Image_Service();
1347
-
1348
-		/** Adapters. */
1349
-		$this->entity_type_adapter    = new Wordlift_Entity_Type_Adapter( $this->entity_type_service );
1350
-		$this->publisher_ajax_adapter = new Wordlift_Publisher_Ajax_Adapter( $this->publisher_service );
1351
-		$this->tinymce_adapter        = new Wordlift_Tinymce_Adapter( $this );
1352
-		//$this->faq_tinymce_adapter      = new Faq_Tinymce_Adapter();
1353
-		$this->relation_rebuild_adapter = new Wordlift_Relation_Rebuild_Adapter( $this->relation_rebuild_service );
1354
-
1355
-		/*
1289
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-term-jsonld-adapter.php';
1290
+        $term_jsonld_adapter = new Wordlift_Term_JsonLd_Adapter( $this->entity_uri_service, $this->jsonld_service );
1291
+        $jsonld_service      = new Jsonld_Service(
1292
+            $this->jsonld_service,
1293
+            $term_jsonld_adapter,
1294
+            new Jsonld_User_Service( $this->user_service ) );
1295
+        new Jsonld_Endpoint( $jsonld_service, $this->entity_uri_service );
1296
+
1297
+        // Prints the JSON-LD in the head.
1298
+        new Jsonld_Adapter( $this->jsonld_service );
1299
+
1300
+        new Jsonld_By_Id_Endpoint( $this->jsonld_service, $this->entity_uri_service );
1301
+
1302
+        $this->key_validation_service = new Wordlift_Key_Validation_Service( $this->configuration_service );
1303
+        $this->content_filter_service = new Wordlift_Content_Filter_Service( $this->entity_service, $this->configuration_service, $this->entity_uri_service );
1304
+        // Creating Faq Content filter service.
1305
+        $this->faq_content_filter_service = new Faq_Content_Filter();
1306
+        $this->relation_rebuild_service   = new Wordlift_Relation_Rebuild_Service( $this->content_filter_service, $this->entity_service );
1307
+        $this->sample_data_service        = new Wordlift_Sample_Data_Service( $this->entity_type_service, $this->configuration_service, $this->user_service );
1308
+        $this->sample_data_ajax_adapter   = new Wordlift_Sample_Data_Ajax_Adapter( $this->sample_data_service );
1309
+        $this->reference_rebuild_service  = new Wordlift_Reference_Rebuild_Service( $this->entity_service );
1310
+
1311
+        $this->loader->add_action( 'enqueue_block_editor_assets', $this, 'add_wl_enabled_blocks' );
1312
+
1313
+        /**
1314
+         * Filter: wl_feature__enable__blocks.
1315
+         *
1316
+         * @param bool whether the blocks needed to be registered, defaults to true.
1317
+         *
1318
+         * @return bool
1319
+         * @since 3.27.6
1320
+         */
1321
+        if ( apply_filters( 'wl_feature__enable__blocks', true ) ) {
1322
+            // Initialize the short-codes.
1323
+            new Async_Template_Decorator( new Wordlift_Navigator_Shortcode() );
1324
+            new Wordlift_Chord_Shortcode();
1325
+            new Wordlift_Geomap_Shortcode();
1326
+            new Wordlift_Timeline_Shortcode();
1327
+            new Wordlift_Related_Entities_Cloud_Shortcode( $this->relation_service );
1328
+            new Wordlift_Vocabulary_Shortcode( $this->configuration_service );
1329
+            new Async_Template_Decorator( new Wordlift_Faceted_Search_Shortcode() );
1330
+        }
1331
+
1332
+        new Wordlift_Products_Navigator_Shortcode();
1333
+
1334
+
1335
+        // Initialize the Context Cards Service
1336
+        $this->context_cards_service = new Wordlift_Context_Cards_Service();
1337
+
1338
+        // Initialize the SEO service.
1339
+        new Wordlift_Seo_Service();
1340
+
1341
+        // Initialize the AMP service.
1342
+        new Wordlift_AMP_Service( $this->jsonld_service );
1343
+
1344
+        /** Services. */
1345
+        $this->google_analytics_export_service = new Wordlift_Google_Analytics_Export_Service();
1346
+        new Wordlift_Image_Service();
1347
+
1348
+        /** Adapters. */
1349
+        $this->entity_type_adapter    = new Wordlift_Entity_Type_Adapter( $this->entity_type_service );
1350
+        $this->publisher_ajax_adapter = new Wordlift_Publisher_Ajax_Adapter( $this->publisher_service );
1351
+        $this->tinymce_adapter        = new Wordlift_Tinymce_Adapter( $this );
1352
+        //$this->faq_tinymce_adapter      = new Faq_Tinymce_Adapter();
1353
+        $this->relation_rebuild_adapter = new Wordlift_Relation_Rebuild_Adapter( $this->relation_rebuild_service );
1354
+
1355
+        /*
1356 1356
 		 * Exclude our public js from WP-Rocket.
1357 1357
 		 *
1358 1358
 		 * @since 3.19.4
1359 1359
 		 *
1360 1360
 		 * @see https://github.com/insideout10/wordlift-plugin/issues/842.
1361 1361
 		 */
1362
-		new Wordlift_WpRocket_Adapter();
1363
-
1364
-		// Create a Rebuild Service instance, which we'll later bound to an ajax call.
1365
-		$this->rebuild_service = new Wordlift_Rebuild_Service(
1366
-			$this->sparql_service,
1367
-			$uri_service
1368
-		);
1369
-
1370
-		$that = $this;
1371
-		add_action( 'plugins_loaded', function () use ( $that ) {
1372
-			if ( ! apply_filters( 'wl_feature__enable__dataset-ng', false ) ) {
1373
-				new Wordlift_Linked_Data_Service( $that->entity_service, $that->entity_type_service, $that->schema_service, $that->sparql_service );
1374
-				new Wordlift_Sparql_Query_Async_Task();
1375
-				new Wordlift_Push_References_Async_Task();
1376
-			}
1377
-		} );
1378
-
1379
-		/** WordPress Admin UI. */
1380
-
1381
-		// UI elements.
1382
-		$this->input_element           = new Wordlift_Admin_Input_Element();
1383
-		$this->radio_input_element     = new Wordlift_Admin_Radio_Input_Element();
1384
-		$this->select2_element         = new Wordlift_Admin_Select2_Element();
1385
-		$this->language_select_element = new Wordlift_Admin_Language_Select_Element();
1386
-		$this->country_select_element  = new Wordlift_Admin_Country_Select_Element();
1387
-		$tabs_element                  = new Wordlift_Admin_Tabs_Element();
1388
-		$this->publisher_element       = new Wordlift_Admin_Publisher_Element( $this->configuration_service, $this->publisher_service, $tabs_element, $this->select2_element );
1389
-		$this->author_element          = new Wordlift_Admin_Author_Element( $this->publisher_service, $this->select2_element );
1390
-
1391
-		$this->settings_page             = new Wordlift_Admin_Settings_Page( $this->configuration_service, $this->entity_service, $this->input_element, $this->language_select_element, $this->country_select_element, $this->publisher_element, $this->radio_input_element );
1392
-		$this->settings_page_action_link = new Wordlift_Admin_Settings_Page_Action_Link( $this->settings_page );
1393
-
1394
-		$this->analytics_settings_page             = new Wordlift_Admin_Settings_Analytics_Page( $this->configuration_service, $this->input_element, $this->radio_input_element );
1395
-		$this->analytics_settings_page_action_link = new Wordlift_Admin_Settings_Analytics_Page_Action_Link( $this->analytics_settings_page );
1396
-		$this->analytics_connect                   = new Wordlift_Analytics_Connect();
1397
-
1398
-		// Pages.
1399
-		/*
1362
+        new Wordlift_WpRocket_Adapter();
1363
+
1364
+        // Create a Rebuild Service instance, which we'll later bound to an ajax call.
1365
+        $this->rebuild_service = new Wordlift_Rebuild_Service(
1366
+            $this->sparql_service,
1367
+            $uri_service
1368
+        );
1369
+
1370
+        $that = $this;
1371
+        add_action( 'plugins_loaded', function () use ( $that ) {
1372
+            if ( ! apply_filters( 'wl_feature__enable__dataset-ng', false ) ) {
1373
+                new Wordlift_Linked_Data_Service( $that->entity_service, $that->entity_type_service, $that->schema_service, $that->sparql_service );
1374
+                new Wordlift_Sparql_Query_Async_Task();
1375
+                new Wordlift_Push_References_Async_Task();
1376
+            }
1377
+        } );
1378
+
1379
+        /** WordPress Admin UI. */
1380
+
1381
+        // UI elements.
1382
+        $this->input_element           = new Wordlift_Admin_Input_Element();
1383
+        $this->radio_input_element     = new Wordlift_Admin_Radio_Input_Element();
1384
+        $this->select2_element         = new Wordlift_Admin_Select2_Element();
1385
+        $this->language_select_element = new Wordlift_Admin_Language_Select_Element();
1386
+        $this->country_select_element  = new Wordlift_Admin_Country_Select_Element();
1387
+        $tabs_element                  = new Wordlift_Admin_Tabs_Element();
1388
+        $this->publisher_element       = new Wordlift_Admin_Publisher_Element( $this->configuration_service, $this->publisher_service, $tabs_element, $this->select2_element );
1389
+        $this->author_element          = new Wordlift_Admin_Author_Element( $this->publisher_service, $this->select2_element );
1390
+
1391
+        $this->settings_page             = new Wordlift_Admin_Settings_Page( $this->configuration_service, $this->entity_service, $this->input_element, $this->language_select_element, $this->country_select_element, $this->publisher_element, $this->radio_input_element );
1392
+        $this->settings_page_action_link = new Wordlift_Admin_Settings_Page_Action_Link( $this->settings_page );
1393
+
1394
+        $this->analytics_settings_page             = new Wordlift_Admin_Settings_Analytics_Page( $this->configuration_service, $this->input_element, $this->radio_input_element );
1395
+        $this->analytics_settings_page_action_link = new Wordlift_Admin_Settings_Analytics_Page_Action_Link( $this->analytics_settings_page );
1396
+        $this->analytics_connect                   = new Wordlift_Analytics_Connect();
1397
+
1398
+        // Pages.
1399
+        /*
1400 1400
 		 * Call the `wl_can_see_classification_box` filter to determine whether we can display the classification box.
1401 1401
 		 *
1402 1402
 		 * @since 3.20.3
1403 1403
 		 *
1404 1404
 		 * @see https://github.com/insideout10/wordlift-plugin/issues/914
1405 1405
 		 */
1406
-		if ( apply_filters( 'wl_can_see_classification_box', true ) ) {
1407
-			require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-post-edit-page.php';
1408
-			new Wordlift_Admin_Post_Edit_Page( $this );
1409
-		}
1410
-		new Wordlift_Entity_Type_Admin_Service();
1406
+        if ( apply_filters( 'wl_can_see_classification_box', true ) ) {
1407
+            require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-post-edit-page.php';
1408
+            new Wordlift_Admin_Post_Edit_Page( $this );
1409
+        }
1410
+        new Wordlift_Entity_Type_Admin_Service();
1411 1411
 
1412
-		// create an instance of the entity type list admin page controller.
1413
-		$this->entity_type_admin_page = new Wordlift_Admin_Entity_Taxonomy_List_Page();
1412
+        // create an instance of the entity type list admin page controller.
1413
+        $this->entity_type_admin_page = new Wordlift_Admin_Entity_Taxonomy_List_Page();
1414 1414
 
1415
-		// create an instance of the entity type setting admin page controller.
1416
-		$this->entity_type_settings_admin_page = new Wordlift_Admin_Entity_Type_Settings();
1415
+        // create an instance of the entity type setting admin page controller.
1416
+        $this->entity_type_settings_admin_page = new Wordlift_Admin_Entity_Type_Settings();
1417 1417
 
1418
-		/** Widgets */
1419
-		$this->related_entities_cloud_widget = new Wordlift_Related_Entities_Cloud_Widget();
1418
+        /** Widgets */
1419
+        $this->related_entities_cloud_widget = new Wordlift_Related_Entities_Cloud_Widget();
1420 1420
 
1421
-		/* WordPress Admin. */
1422
-		$this->download_your_data_page = new Wordlift_Admin_Download_Your_Data_Page( $this->configuration_service );
1423
-		$this->status_page             = new Wordlift_Admin_Status_Page( $this->entity_service, $this->sparql_service );
1421
+        /* WordPress Admin. */
1422
+        $this->download_your_data_page = new Wordlift_Admin_Download_Your_Data_Page( $this->configuration_service );
1423
+        $this->status_page             = new Wordlift_Admin_Status_Page( $this->entity_service, $this->sparql_service );
1424 1424
 
1425
-		// Create an instance of the install wizard.
1426
-		$this->admin_setup = new Wordlift_Admin_Setup( $this->configuration_service, $this->key_validation_service, $this->entity_service, $this->language_select_element, $this->country_select_element );
1425
+        // Create an instance of the install wizard.
1426
+        $this->admin_setup = new Wordlift_Admin_Setup( $this->configuration_service, $this->key_validation_service, $this->entity_service, $this->language_select_element, $this->country_select_element );
1427 1427
 
1428
-		$this->category_taxonomy_service = new Wordlift_Category_Taxonomy_Service( $this->entity_post_type_service );
1428
+        $this->category_taxonomy_service = new Wordlift_Category_Taxonomy_Service( $this->entity_post_type_service );
1429 1429
 
1430
-		// User Profile.
1431
-		new Wordlift_Admin_User_Profile_Page( $this->author_element, $this->user_service );
1430
+        // User Profile.
1431
+        new Wordlift_Admin_User_Profile_Page( $this->author_element, $this->user_service );
1432 1432
 
1433
-		$this->entity_page_service = new Wordlift_Entity_Page_Service();
1433
+        $this->entity_page_service = new Wordlift_Entity_Page_Service();
1434 1434
 
1435
-		// Load the debug service if WP is in debug mode.
1436
-		if ( defined( 'WP_DEBUG' ) && WP_DEBUG ) {
1437
-			require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-debug-service.php';
1438
-			new Wordlift_Debug_Service( $this->entity_service, $uri_service );
1439
-		}
1435
+        // Load the debug service if WP is in debug mode.
1436
+        if ( defined( 'WP_DEBUG' ) && WP_DEBUG ) {
1437
+            require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-debug-service.php';
1438
+            new Wordlift_Debug_Service( $this->entity_service, $uri_service );
1439
+        }
1440 1440
 
1441
-		// Remote Image Service.
1442
-		new Wordlift_Remote_Image_Service();
1441
+        // Remote Image Service.
1442
+        new Wordlift_Remote_Image_Service();
1443 1443
 
1444
-		/*
1444
+        /*
1445 1445
 		 * Provides mappings between post types and entity types.
1446 1446
 		 *
1447 1447
 		 * @since 3.20.0
1448 1448
 		 *
1449 1449
 		 * @see https://github.com/insideout10/wordlift-plugin/issues/852.
1450 1450
 		 */
1451
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-batch-action.php';
1452
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/mapping/class-wordlift-mapping-service.php';
1453
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/mapping/class-wordlift-mapping-ajax-adapter.php';
1451
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-batch-action.php';
1452
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/mapping/class-wordlift-mapping-service.php';
1453
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/mapping/class-wordlift-mapping-ajax-adapter.php';
1454 1454
 
1455
-		// Create an instance of the Mapping Service and assign it to the Ajax Adapter.
1456
-		new Wordlift_Mapping_Ajax_Adapter( new Wordlift_Mapping_Service( Wordlift_Entity_Type_Service::get_instance() ) );
1455
+        // Create an instance of the Mapping Service and assign it to the Ajax Adapter.
1456
+        new Wordlift_Mapping_Ajax_Adapter( new Wordlift_Mapping_Service( Wordlift_Entity_Type_Service::get_instance() ) );
1457 1457
 
1458
-		/*
1458
+        /*
1459 1459
 		 * Batch Operations. They're similar to Batch Actions but do not require working on post types.
1460 1460
 		 *
1461 1461
 		 * Eventually Batch Actions will become Batch Operations.
1462 1462
 		 *
1463 1463
 		 * @since 3.20.0
1464 1464
 		 */
1465
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/batch/intf-wordlift-batch-operation.php';
1466
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/batch/class-wordlift-batch-operation-ajax-adapter.php';
1465
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/batch/intf-wordlift-batch-operation.php';
1466
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/batch/class-wordlift-batch-operation-ajax-adapter.php';
1467 1467
 
1468
-		/*
1468
+        /*
1469 1469
 		 * Add the Search Keywords taxonomy to manage the Search Keywords on WLS.
1470 1470
 		 *
1471 1471
 		 * @link https://github.com/insideout10/wordlift-plugin/issues/761
1472 1472
 		 *
1473 1473
 		 * @since 3.20.0
1474 1474
 		 */
1475
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/search-keywords/class-wordlift-search-keyword-taxonomy.php';
1476
-		new Wordlift_Search_Keyword_Taxonomy( $api_service );
1475
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/search-keywords/class-wordlift-search-keyword-taxonomy.php';
1476
+        new Wordlift_Search_Keyword_Taxonomy( $api_service );
1477 1477
 
1478
-		/*
1478
+        /*
1479 1479
 		 * Load the Mappings JSON-LD post processing.
1480 1480
 		 *
1481 1481
 		 * @since 3.25.0
1482 1482
 		 */
1483 1483
 
1484
-		$mappings_dbo           = new Mappings_DBO();
1485
-		$default_rule_validator = new Taxonomy_Rule_Validator();
1486
-		new Post_Type_Rule_Validator();
1487
-		// Taxonomy term rule validator for validating rules for term pages.
1488
-		new Taxonomy_Term_Rule_Validator();
1489
-		$rule_validators_registry = new Rule_Validators_Registry( $default_rule_validator );
1490
-		$rule_groups_validator    = new Rule_Groups_Validator( $rule_validators_registry );
1491
-		$mappings_validator       = new Mappings_Validator( $mappings_dbo, $rule_groups_validator );
1492
-
1493
-		new Url_To_Entity_Transform_Function( $this->entity_uri_service );
1494
-		new Taxonomy_To_Terms_Transform_Function();
1495
-		new Post_Id_To_Entity_Transform_Function();
1496
-		$mappings_transform_functions_registry = new Mappings_Transform_Functions_Registry();
1497
-
1498
-		/**
1499
-		 * @since 3.27.1
1500
-		 * Intiailize the acf group data formatter.
1501
-		 */
1502
-		new Acf_Group_Formatter();
1503
-		new Jsonld_Converter( $mappings_validator, $mappings_transform_functions_registry );
1504
-
1505
-		/**
1506
-		 * @since 3.26.0
1507
-		 * Initialize the Faq JSON LD converter here - disabled.
1508
-		 */
1509
-		// new Faq_To_Jsonld_Converter();
1510
-		/*
1484
+        $mappings_dbo           = new Mappings_DBO();
1485
+        $default_rule_validator = new Taxonomy_Rule_Validator();
1486
+        new Post_Type_Rule_Validator();
1487
+        // Taxonomy term rule validator for validating rules for term pages.
1488
+        new Taxonomy_Term_Rule_Validator();
1489
+        $rule_validators_registry = new Rule_Validators_Registry( $default_rule_validator );
1490
+        $rule_groups_validator    = new Rule_Groups_Validator( $rule_validators_registry );
1491
+        $mappings_validator       = new Mappings_Validator( $mappings_dbo, $rule_groups_validator );
1492
+
1493
+        new Url_To_Entity_Transform_Function( $this->entity_uri_service );
1494
+        new Taxonomy_To_Terms_Transform_Function();
1495
+        new Post_Id_To_Entity_Transform_Function();
1496
+        $mappings_transform_functions_registry = new Mappings_Transform_Functions_Registry();
1497
+
1498
+        /**
1499
+         * @since 3.27.1
1500
+         * Intiailize the acf group data formatter.
1501
+         */
1502
+        new Acf_Group_Formatter();
1503
+        new Jsonld_Converter( $mappings_validator, $mappings_transform_functions_registry );
1504
+
1505
+        /**
1506
+         * @since 3.26.0
1507
+         * Initialize the Faq JSON LD converter here - disabled.
1508
+         */
1509
+        // new Faq_To_Jsonld_Converter();
1510
+        /*
1511 1511
 		 * Use the Templates Ajax Endpoint to load HTML templates for the legacy Angular app via admin-ajax.php
1512 1512
 		 * end-point.
1513 1513
 		 *
1514 1514
 		 * @see https://github.com/insideout10/wordlift-plugin/issues/834
1515 1515
 		 * @since 3.24.4
1516 1516
 		 */
1517
-		new Templates_Ajax_Endpoint();
1518
-		// Call this static method to register FAQ routes to rest api - disabled
1519
-		//Faq_Rest_Controller::register_routes();
1517
+        new Templates_Ajax_Endpoint();
1518
+        // Call this static method to register FAQ routes to rest api - disabled
1519
+        //Faq_Rest_Controller::register_routes();
1520 1520
 
1521
-		/*
1521
+        /*
1522 1522
 		 * Create a singleton for the Analysis_Response_Ops_Factory.
1523 1523
 		 */
1524
-		$entity_helper = new Entity_Helper( $this->entity_uri_service, $this->entity_service );
1525
-		new Analysis_Response_Ops_Factory(
1526
-			$this->entity_uri_service,
1527
-			$this->entity_service,
1528
-			$this->entity_type_service,
1529
-			$this->storage_factory->post_images(),
1530
-			$entity_helper
1531
-		);
1532
-
1533
-		/** WL Autocomplete. */
1534
-		$autocomplete_service       = new All_Autocomplete_Service( array(
1535
-			new Local_Autocomplete_Service(),
1536
-			new Linked_Data_Autocomplete_Service( $this->configuration_service, $entity_helper, $this->entity_uri_service, $this->entity_service ),
1537
-		) );
1538
-		$this->autocomplete_adapter = new Wordlift_Autocomplete_Adapter( $autocomplete_service );
1539
-
1540
-		/**
1541
-		 * @since 3.27.2
1542
-		 * Integrate the recipe maker jsonld & set recipe
1543
-		 * as default entity type to the wprm_recipe CPT.
1544
-		 */
1545
-		new Recipe_Maker_Post_Type_Hook();
1546
-		$recipe_maker_validation_service = new Recipe_Maker_Validation_Service();
1547
-		new Recipe_Maker_Jsonld_Hook( $attachment_service, $recipe_maker_validation_service );
1548
-		new Recipe_Maker_After_Get_Jsonld_Hook( $recipe_maker_validation_service );
1549
-		new Recipe_Maker_Warning( $recipe_maker_validation_service );
1550
-		new Yoast_Jsonld( $recipe_maker_validation_service );
1551
-
1552
-		/**
1553
-		 * @since 3.27.4
1554
-		 * Add the faq duplicate markup hook.
1555
-		 */
1556
-		new Faq_Duplicate_Markup_Remover();
1557
-	}
1558
-
1559
-	/**
1560
-	 * Define the locale for this plugin for internationalization.
1561
-	 *
1562
-	 * Uses the Wordlift_i18n class in order to set the domain and to register the hook
1563
-	 * with WordPress.
1564
-	 *
1565
-	 * @since    1.0.0
1566
-	 * @access   private
1567
-	 */
1568
-	private function set_locale() {
1569
-
1570
-		$plugin_i18n = new Wordlift_i18n();
1571
-		$plugin_i18n->set_domain( $this->get_plugin_name() );
1572
-
1573
-		$this->loader->add_action( 'plugins_loaded', $plugin_i18n, 'load_plugin_textdomain' );
1574
-
1575
-	}
1576
-
1577
-	/**
1578
-	 * Register all of the hooks related to the admin area functionality
1579
-	 * of the plugin.
1580
-	 *
1581
-	 * @since    1.0.0
1582
-	 * @access   private
1583
-	 */
1584
-	private function define_admin_hooks() {
1585
-
1586
-		$plugin_admin = new Wordlift_Admin(
1587
-			$this->get_plugin_name(),
1588
-			$this->get_version(),
1589
-			$this->configuration_service,
1590
-			$this->notice_service,
1591
-			$this->user_service
1592
-		);
1593
-
1594
-		$this->loader->add_action( 'admin_enqueue_scripts', $plugin_admin, 'enqueue_styles' );
1595
-		$this->loader->add_action( 'admin_enqueue_scripts', $plugin_admin, 'enqueue_scripts', 11 );
1596
-
1597
-		// Hook the init action to taxonomy services.
1598
-		$this->loader->add_action( 'init', $this->topic_taxonomy_service, 'init', 0 );
1599
-		$this->loader->add_action( 'init', $this->entity_types_taxonomy_service, 'init', 0 );
1600
-
1601
-		// Hook the deleted_post_meta action to the Thumbnail service.
1602
-		$this->loader->add_action( 'deleted_post_meta', $this->thumbnail_service, 'deleted_post_meta', 10, 4 );
1603
-
1604
-		// Hook the added_post_meta action to the Thumbnail service.
1605
-		$this->loader->add_action( 'added_post_meta', $this->thumbnail_service, 'added_or_updated_post_meta', 10, 4 );
1606
-
1607
-		// Hook the updated_post_meta action to the Thumbnail service.
1608
-		$this->loader->add_action( 'updated_post_meta', $this->thumbnail_service, 'added_or_updated_post_meta', 10, 4 );
1609
-
1610
-		// Hook the AJAX wl_timeline action to the Timeline service.
1611
-		$this->loader->add_action( 'wp_ajax_wl_timeline', $this->timeline_service, 'ajax_timeline' );
1612
-
1613
-		// Register custom allowed redirect hosts.
1614
-		$this->loader->add_filter( 'allowed_redirect_hosts', $this->redirect_service, 'allowed_redirect_hosts' );
1615
-		// Hook the AJAX wordlift_redirect action to the Redirect service.
1616
-		$this->loader->add_action( 'wp_ajax_wordlift_redirect', $this->redirect_service, 'ajax_redirect' );
1617
-
1618
-		/*
1524
+        $entity_helper = new Entity_Helper( $this->entity_uri_service, $this->entity_service );
1525
+        new Analysis_Response_Ops_Factory(
1526
+            $this->entity_uri_service,
1527
+            $this->entity_service,
1528
+            $this->entity_type_service,
1529
+            $this->storage_factory->post_images(),
1530
+            $entity_helper
1531
+        );
1532
+
1533
+        /** WL Autocomplete. */
1534
+        $autocomplete_service       = new All_Autocomplete_Service( array(
1535
+            new Local_Autocomplete_Service(),
1536
+            new Linked_Data_Autocomplete_Service( $this->configuration_service, $entity_helper, $this->entity_uri_service, $this->entity_service ),
1537
+        ) );
1538
+        $this->autocomplete_adapter = new Wordlift_Autocomplete_Adapter( $autocomplete_service );
1539
+
1540
+        /**
1541
+         * @since 3.27.2
1542
+         * Integrate the recipe maker jsonld & set recipe
1543
+         * as default entity type to the wprm_recipe CPT.
1544
+         */
1545
+        new Recipe_Maker_Post_Type_Hook();
1546
+        $recipe_maker_validation_service = new Recipe_Maker_Validation_Service();
1547
+        new Recipe_Maker_Jsonld_Hook( $attachment_service, $recipe_maker_validation_service );
1548
+        new Recipe_Maker_After_Get_Jsonld_Hook( $recipe_maker_validation_service );
1549
+        new Recipe_Maker_Warning( $recipe_maker_validation_service );
1550
+        new Yoast_Jsonld( $recipe_maker_validation_service );
1551
+
1552
+        /**
1553
+         * @since 3.27.4
1554
+         * Add the faq duplicate markup hook.
1555
+         */
1556
+        new Faq_Duplicate_Markup_Remover();
1557
+    }
1558
+
1559
+    /**
1560
+     * Define the locale for this plugin for internationalization.
1561
+     *
1562
+     * Uses the Wordlift_i18n class in order to set the domain and to register the hook
1563
+     * with WordPress.
1564
+     *
1565
+     * @since    1.0.0
1566
+     * @access   private
1567
+     */
1568
+    private function set_locale() {
1569
+
1570
+        $plugin_i18n = new Wordlift_i18n();
1571
+        $plugin_i18n->set_domain( $this->get_plugin_name() );
1572
+
1573
+        $this->loader->add_action( 'plugins_loaded', $plugin_i18n, 'load_plugin_textdomain' );
1574
+
1575
+    }
1576
+
1577
+    /**
1578
+     * Register all of the hooks related to the admin area functionality
1579
+     * of the plugin.
1580
+     *
1581
+     * @since    1.0.0
1582
+     * @access   private
1583
+     */
1584
+    private function define_admin_hooks() {
1585
+
1586
+        $plugin_admin = new Wordlift_Admin(
1587
+            $this->get_plugin_name(),
1588
+            $this->get_version(),
1589
+            $this->configuration_service,
1590
+            $this->notice_service,
1591
+            $this->user_service
1592
+        );
1593
+
1594
+        $this->loader->add_action( 'admin_enqueue_scripts', $plugin_admin, 'enqueue_styles' );
1595
+        $this->loader->add_action( 'admin_enqueue_scripts', $plugin_admin, 'enqueue_scripts', 11 );
1596
+
1597
+        // Hook the init action to taxonomy services.
1598
+        $this->loader->add_action( 'init', $this->topic_taxonomy_service, 'init', 0 );
1599
+        $this->loader->add_action( 'init', $this->entity_types_taxonomy_service, 'init', 0 );
1600
+
1601
+        // Hook the deleted_post_meta action to the Thumbnail service.
1602
+        $this->loader->add_action( 'deleted_post_meta', $this->thumbnail_service, 'deleted_post_meta', 10, 4 );
1603
+
1604
+        // Hook the added_post_meta action to the Thumbnail service.
1605
+        $this->loader->add_action( 'added_post_meta', $this->thumbnail_service, 'added_or_updated_post_meta', 10, 4 );
1606
+
1607
+        // Hook the updated_post_meta action to the Thumbnail service.
1608
+        $this->loader->add_action( 'updated_post_meta', $this->thumbnail_service, 'added_or_updated_post_meta', 10, 4 );
1609
+
1610
+        // Hook the AJAX wl_timeline action to the Timeline service.
1611
+        $this->loader->add_action( 'wp_ajax_wl_timeline', $this->timeline_service, 'ajax_timeline' );
1612
+
1613
+        // Register custom allowed redirect hosts.
1614
+        $this->loader->add_filter( 'allowed_redirect_hosts', $this->redirect_service, 'allowed_redirect_hosts' );
1615
+        // Hook the AJAX wordlift_redirect action to the Redirect service.
1616
+        $this->loader->add_action( 'wp_ajax_wordlift_redirect', $this->redirect_service, 'ajax_redirect' );
1617
+
1618
+        /*
1619 1619
 		 * The old dashboard is replaced with dashboard v2.
1620 1620
 		 *
1621 1621
 		 * The old dashboard service is still loaded because its functions are used.
@@ -1624,389 +1624,389 @@  discard block
 block discarded – undo
1624 1624
 		 *
1625 1625
 		 * @since 3.20.0
1626 1626
 		 */
1627
-		// Hook the AJAX wordlift_redirect action to the Redirect service.
1628
-		// $this->loader->add_action( 'wp_ajax_wordlift_get_stats', $this->dashboard_service, 'ajax_get_stats' );
1629
-		// Hook the AJAX wordlift_redirect action to the Redirect service.
1630
-		// $this->loader->add_action( 'wp_dashboard_setup', $this->dashboard_service, 'add_dashboard_widgets' );
1631
-
1632
-		// Hook save_post to the entity service to update custom fields (such as alternate labels).
1633
-		// We have a priority of 9 because we want to be executed before data is sent to Redlink.
1634
-		$this->loader->add_action( 'save_post', $this->entity_service, 'save_post', 9, 3 );
1635
-		$this->loader->add_action( 'save_post', $this->rating_service, 'set_rating_for', 20, 1 );
1636
-
1637
-		$this->loader->add_action( 'edit_form_before_permalink', $this->entity_service, 'edit_form_before_permalink', 10, 1 );
1638
-		$this->loader->add_action( 'in_admin_header', $this->rating_service, 'in_admin_header' );
1639
-
1640
-		// Entity listing customization (wp-admin/edit.php)
1641
-		// Add custom columns.
1642
-		$this->loader->add_filter( 'manage_entity_posts_columns', $this->entity_list_service, 'register_custom_columns' );
1643
-		// no explicit entity as it prevents handling of other post types.
1644
-		$this->loader->add_filter( 'manage_posts_custom_column', $this->entity_list_service, 'render_custom_columns', 10, 2 );
1645
-		// Add 4W selection.
1646
-		$this->loader->add_action( 'restrict_manage_posts', $this->entity_list_service, 'restrict_manage_posts_classification_scope' );
1647
-		$this->loader->add_filter( 'posts_clauses', $this->entity_list_service, 'posts_clauses_classification_scope' );
1648
-		$this->loader->add_action( 'pre_get_posts', $this->entity_list_service, 'pre_get_posts' );
1649
-		$this->loader->add_action( 'load-edit.php', $this->entity_list_service, 'load_edit' );
1650
-
1651
-		/*
1627
+        // Hook the AJAX wordlift_redirect action to the Redirect service.
1628
+        // $this->loader->add_action( 'wp_ajax_wordlift_get_stats', $this->dashboard_service, 'ajax_get_stats' );
1629
+        // Hook the AJAX wordlift_redirect action to the Redirect service.
1630
+        // $this->loader->add_action( 'wp_dashboard_setup', $this->dashboard_service, 'add_dashboard_widgets' );
1631
+
1632
+        // Hook save_post to the entity service to update custom fields (such as alternate labels).
1633
+        // We have a priority of 9 because we want to be executed before data is sent to Redlink.
1634
+        $this->loader->add_action( 'save_post', $this->entity_service, 'save_post', 9, 3 );
1635
+        $this->loader->add_action( 'save_post', $this->rating_service, 'set_rating_for', 20, 1 );
1636
+
1637
+        $this->loader->add_action( 'edit_form_before_permalink', $this->entity_service, 'edit_form_before_permalink', 10, 1 );
1638
+        $this->loader->add_action( 'in_admin_header', $this->rating_service, 'in_admin_header' );
1639
+
1640
+        // Entity listing customization (wp-admin/edit.php)
1641
+        // Add custom columns.
1642
+        $this->loader->add_filter( 'manage_entity_posts_columns', $this->entity_list_service, 'register_custom_columns' );
1643
+        // no explicit entity as it prevents handling of other post types.
1644
+        $this->loader->add_filter( 'manage_posts_custom_column', $this->entity_list_service, 'render_custom_columns', 10, 2 );
1645
+        // Add 4W selection.
1646
+        $this->loader->add_action( 'restrict_manage_posts', $this->entity_list_service, 'restrict_manage_posts_classification_scope' );
1647
+        $this->loader->add_filter( 'posts_clauses', $this->entity_list_service, 'posts_clauses_classification_scope' );
1648
+        $this->loader->add_action( 'pre_get_posts', $this->entity_list_service, 'pre_get_posts' );
1649
+        $this->loader->add_action( 'load-edit.php', $this->entity_list_service, 'load_edit' );
1650
+
1651
+        /*
1652 1652
 		 * If `All Entity Types` is disable, use the radio button Walker.
1653 1653
 		 *
1654 1654
 		 * @see https://github.com/insideout10/wordlift-plugin/issues/835
1655 1655
 		 */
1656
-		if ( ! WL_ALL_ENTITY_TYPES ) {
1657
-			$this->loader->add_filter( 'wp_terms_checklist_args', $this->entity_types_taxonomy_walker, 'terms_checklist_args' );
1658
-		}
1659
-
1660
-		// Hook the PrimaShop adapter to <em>prima_metabox_entity_header_args</em> in order to add header support for
1661
-		// entities.
1662
-		$this->loader->add_filter( 'prima_metabox_entity_header_args', $this->primashop_adapter, 'prima_metabox_entity_header_args', 10, 2 );
1663
-
1664
-		// Filter imported post meta.
1665
-		$this->loader->add_filter( 'wp_import_post_meta', $this->import_service, 'wp_import_post_meta', 10, 3 );
1666
-
1667
-		// Notify the import service when an import starts and ends.
1668
-		$this->loader->add_action( 'import_start', $this->import_service, 'import_start', 10, 0 );
1669
-		$this->loader->add_action( 'import_end', $this->import_service, 'import_end', 10, 0 );
1670
-
1671
-		// Hook the AJAX wl_rebuild action to the Rebuild Service.
1672
-		$this->loader->add_action( 'wp_ajax_wl_rebuild', $this->rebuild_service, 'rebuild' );
1673
-		$this->loader->add_action( 'wp_ajax_wl_rebuild_references', $this->reference_rebuild_service, 'rebuild' );
1674
-
1675
-		/**
1676
-		 * Filter: wl_feature__enable__screens.
1677
-		 *
1678
-		 * @param bool whether the screens needed to be registered, defaults to true.
1679
-		 *
1680
-		 * @return bool
1681
-		 * @since 3.27.6
1682
-		 */
1683
-		if ( apply_filters( 'wl_feature__enable__screens', true ) ) {
1684
-			// Hook the menu to the Download Your Data page.
1685
-			$this->loader->add_action( 'admin_menu', $this->download_your_data_page, 'admin_menu', 100, 0 );
1686
-			$this->loader->add_action( 'admin_menu', $this->status_page, 'admin_menu', 100, 0 );
1687
-			$this->loader->add_action( 'admin_menu', $this->entity_type_settings_admin_page, 'admin_menu', 100, 0 );
1688
-		}
1689
-		// Hook the admin-ajax.php?action=wl_download_your_data&out=xyz links.
1690
-		$this->loader->add_action( 'wp_ajax_wl_download_your_data', $this->download_your_data_page, 'download_your_data', 10 );
1691
-
1692
-		// Hook the AJAX wl_jsonld action to the JSON-LD service.
1693
-		$this->loader->add_action( 'wp_ajax_wl_jsonld', $this->jsonld_service, 'get' );
1694
-		$this->loader->add_action( 'admin_post_wl_jsonld', $this->jsonld_service, 'get' );
1695
-		$this->loader->add_action( 'admin_post_nopriv_wl_jsonld', $this->jsonld_service, 'get' );
1696
-
1697
-		// Hook the AJAX wl_validate_key action to the Key Validation service.
1698
-		$this->loader->add_action( 'wp_ajax_wl_validate_key', $this->key_validation_service, 'validate_key' );
1699
-
1700
-		// Hook the AJAX wl_update_country_options action to the countries.
1701
-		$this->loader->add_action( 'wp_ajax_wl_update_country_options', $this->country_select_element, 'get_options_html' );
1702
-
1703
-		// Hook the `admin_init` function to the Admin Setup.
1704
-		$this->loader->add_action( 'admin_init', $this->admin_setup, 'admin_init' );
1705
-
1706
-		// Hook the admin_init to the settings page.
1707
-		$this->loader->add_action( 'admin_init', $this->settings_page, 'admin_init' );
1708
-		$this->loader->add_action( 'admin_init', $this->analytics_settings_page, 'admin_init' );
1709
-
1710
-		$this->loader->add_filter( 'admin_post_thumbnail_html', $this->publisher_service, 'add_featured_image_instruction' );
1711
-
1712
-		// Hook the menu creation on the general wordlift menu creation.
1713
-		/**
1714
-		 * Filter: wl_feature__enable__screens.
1715
-		 *
1716
-		 * @param bool whether the screens needed to be registered, defaults to true.
1717
-		 *
1718
-		 * @return bool
1719
-		 * @since 3.27.6
1720
-		 */
1721
-		if ( apply_filters( 'wl_feature__enable__screens', true ) ) {
1722
-			$this->loader->add_action( 'wl_admin_menu', $this->settings_page, 'admin_menu', 10, 2 );
1723
-		}
1724
-		/*
1656
+        if ( ! WL_ALL_ENTITY_TYPES ) {
1657
+            $this->loader->add_filter( 'wp_terms_checklist_args', $this->entity_types_taxonomy_walker, 'terms_checklist_args' );
1658
+        }
1659
+
1660
+        // Hook the PrimaShop adapter to <em>prima_metabox_entity_header_args</em> in order to add header support for
1661
+        // entities.
1662
+        $this->loader->add_filter( 'prima_metabox_entity_header_args', $this->primashop_adapter, 'prima_metabox_entity_header_args', 10, 2 );
1663
+
1664
+        // Filter imported post meta.
1665
+        $this->loader->add_filter( 'wp_import_post_meta', $this->import_service, 'wp_import_post_meta', 10, 3 );
1666
+
1667
+        // Notify the import service when an import starts and ends.
1668
+        $this->loader->add_action( 'import_start', $this->import_service, 'import_start', 10, 0 );
1669
+        $this->loader->add_action( 'import_end', $this->import_service, 'import_end', 10, 0 );
1670
+
1671
+        // Hook the AJAX wl_rebuild action to the Rebuild Service.
1672
+        $this->loader->add_action( 'wp_ajax_wl_rebuild', $this->rebuild_service, 'rebuild' );
1673
+        $this->loader->add_action( 'wp_ajax_wl_rebuild_references', $this->reference_rebuild_service, 'rebuild' );
1674
+
1675
+        /**
1676
+         * Filter: wl_feature__enable__screens.
1677
+         *
1678
+         * @param bool whether the screens needed to be registered, defaults to true.
1679
+         *
1680
+         * @return bool
1681
+         * @since 3.27.6
1682
+         */
1683
+        if ( apply_filters( 'wl_feature__enable__screens', true ) ) {
1684
+            // Hook the menu to the Download Your Data page.
1685
+            $this->loader->add_action( 'admin_menu', $this->download_your_data_page, 'admin_menu', 100, 0 );
1686
+            $this->loader->add_action( 'admin_menu', $this->status_page, 'admin_menu', 100, 0 );
1687
+            $this->loader->add_action( 'admin_menu', $this->entity_type_settings_admin_page, 'admin_menu', 100, 0 );
1688
+        }
1689
+        // Hook the admin-ajax.php?action=wl_download_your_data&out=xyz links.
1690
+        $this->loader->add_action( 'wp_ajax_wl_download_your_data', $this->download_your_data_page, 'download_your_data', 10 );
1691
+
1692
+        // Hook the AJAX wl_jsonld action to the JSON-LD service.
1693
+        $this->loader->add_action( 'wp_ajax_wl_jsonld', $this->jsonld_service, 'get' );
1694
+        $this->loader->add_action( 'admin_post_wl_jsonld', $this->jsonld_service, 'get' );
1695
+        $this->loader->add_action( 'admin_post_nopriv_wl_jsonld', $this->jsonld_service, 'get' );
1696
+
1697
+        // Hook the AJAX wl_validate_key action to the Key Validation service.
1698
+        $this->loader->add_action( 'wp_ajax_wl_validate_key', $this->key_validation_service, 'validate_key' );
1699
+
1700
+        // Hook the AJAX wl_update_country_options action to the countries.
1701
+        $this->loader->add_action( 'wp_ajax_wl_update_country_options', $this->country_select_element, 'get_options_html' );
1702
+
1703
+        // Hook the `admin_init` function to the Admin Setup.
1704
+        $this->loader->add_action( 'admin_init', $this->admin_setup, 'admin_init' );
1705
+
1706
+        // Hook the admin_init to the settings page.
1707
+        $this->loader->add_action( 'admin_init', $this->settings_page, 'admin_init' );
1708
+        $this->loader->add_action( 'admin_init', $this->analytics_settings_page, 'admin_init' );
1709
+
1710
+        $this->loader->add_filter( 'admin_post_thumbnail_html', $this->publisher_service, 'add_featured_image_instruction' );
1711
+
1712
+        // Hook the menu creation on the general wordlift menu creation.
1713
+        /**
1714
+         * Filter: wl_feature__enable__screens.
1715
+         *
1716
+         * @param bool whether the screens needed to be registered, defaults to true.
1717
+         *
1718
+         * @return bool
1719
+         * @since 3.27.6
1720
+         */
1721
+        if ( apply_filters( 'wl_feature__enable__screens', true ) ) {
1722
+            $this->loader->add_action( 'wl_admin_menu', $this->settings_page, 'admin_menu', 10, 2 );
1723
+        }
1724
+        /*
1725 1725
 		 * Display the `Wordlift_Admin_Search_Rankings_Page` page.
1726 1726
 		 *
1727 1727
 		 * @link https://github.com/insideout10/wordlift-plugin/issues/761
1728 1728
 		 *
1729 1729
 		 * @since 3.20.0
1730 1730
 		 */
1731
-		if ( in_array( $this->configuration_service->get_package_type(), array( 'editorial', 'business' ) ) ) {
1732
-			/**
1733
-			 * Filter: wl_feature__enable__screens.
1734
-			 *
1735
-			 * @param bool whether the screens needed to be registered, defaults to true.
1736
-			 *
1737
-			 * @return bool
1738
-			 * @since 3.27.6
1739
-			 */
1740
-			if ( apply_filters( 'wl_feature__enable__screens', true ) ) {
1741
-				$admin_search_rankings_page = new Wordlift_Admin_Search_Rankings_Page();
1742
-				$this->loader->add_action( 'wl_admin_menu', $admin_search_rankings_page, 'admin_menu' );
1743
-			}
1744
-		}
1745
-
1746
-		// Hook key update.
1747
-		$this->loader->add_action( 'pre_update_option_wl_general_settings', $this->configuration_service, 'maybe_update_dataset_uri', 10, 2 );
1748
-		$this->loader->add_action( 'update_option_wl_general_settings', $this->configuration_service, 'update_key', 10, 2 );
1749
-
1750
-		// Add additional action links to the WordLift plugin in the plugins page.
1751
-		$this->loader->add_filter( 'plugin_action_links_wordlift/wordlift.php', $this->settings_page_action_link, 'action_links', 10, 1 );
1752
-
1753
-		/*
1731
+        if ( in_array( $this->configuration_service->get_package_type(), array( 'editorial', 'business' ) ) ) {
1732
+            /**
1733
+             * Filter: wl_feature__enable__screens.
1734
+             *
1735
+             * @param bool whether the screens needed to be registered, defaults to true.
1736
+             *
1737
+             * @return bool
1738
+             * @since 3.27.6
1739
+             */
1740
+            if ( apply_filters( 'wl_feature__enable__screens', true ) ) {
1741
+                $admin_search_rankings_page = new Wordlift_Admin_Search_Rankings_Page();
1742
+                $this->loader->add_action( 'wl_admin_menu', $admin_search_rankings_page, 'admin_menu' );
1743
+            }
1744
+        }
1745
+
1746
+        // Hook key update.
1747
+        $this->loader->add_action( 'pre_update_option_wl_general_settings', $this->configuration_service, 'maybe_update_dataset_uri', 10, 2 );
1748
+        $this->loader->add_action( 'update_option_wl_general_settings', $this->configuration_service, 'update_key', 10, 2 );
1749
+
1750
+        // Add additional action links to the WordLift plugin in the plugins page.
1751
+        $this->loader->add_filter( 'plugin_action_links_wordlift/wordlift.php', $this->settings_page_action_link, 'action_links', 10, 1 );
1752
+
1753
+        /*
1754 1754
 		 * Remove the Analytics Settings link from the plugin page.
1755 1755
 		 *
1756 1756
 		 * @see https://github.com/insideout10/wordlift-plugin/issues/932
1757 1757
 		 * @since 3.21.1
1758 1758
 		 */
1759
-		// $this->loader->add_filter( 'plugin_action_links_wordlift/wordlift.php', $this->analytics_settings_page_action_link, 'action_links', 10, 1 );
1760
-
1761
-		// Hook the AJAX `wl_publisher` action name.
1762
-		$this->loader->add_action( 'wp_ajax_wl_publisher', $this->publisher_ajax_adapter, 'publisher' );
1763
-
1764
-		// Hook row actions for the entity type list admin.
1765
-		$this->loader->add_filter( 'wl_entity_type_row_actions', $this->entity_type_admin_page, 'wl_entity_type_row_actions', 10, 2 );
1766
-
1767
-		/** Ajax actions. */
1768
-		$this->loader->add_action( 'wp_ajax_wl_google_analytics_export', $this->google_analytics_export_service, 'export' );
1769
-
1770
-		// Hook capabilities manipulation to allow access to entity type admin
1771
-		// page  on WordPress versions before 4.7.
1772
-		global $wp_version;
1773
-		if ( version_compare( $wp_version, '4.7', '<' ) ) {
1774
-			$this->loader->add_filter( 'map_meta_cap', $this->entity_type_admin_page, 'enable_admin_access_pre_47', 10, 4 );
1775
-		}
1776
-
1777
-		$this->loader->add_action( 'wl_async_wl_run_sparql_query', $this->sparql_service, 'run_sparql_query', 10, 1 );
1778
-
1779
-		/** Adapters. */
1780
-		$this->loader->add_filter( 'mce_external_plugins', $this->tinymce_adapter, 'mce_external_plugins', 10, 1 );
1781
-		/**
1782
-		 * Disabling Faq temporarily.
1783
-		 * Load the tinymce editor button on the tool bar.
1784
-		 * @since 3.26.0
1785
-		 */
1786
-		//$this->loader->add_filter( 'tiny_mce_before_init', $this->faq_tinymce_adapter, 'register_custom_tags' );
1787
-		//$this->loader->add_filter( 'mce_buttons', $this->faq_tinymce_adapter, 'register_faq_toolbar_button', 10, 1 );
1788
-		//$this->loader->add_filter( 'mce_external_plugins', $this->faq_tinymce_adapter, 'register_faq_tinymce_plugin', 10, 1 );
1789
-
1790
-
1791
-		$this->loader->add_action( 'wp_ajax_wl_relation_rebuild_process_all', $this->relation_rebuild_adapter, 'process_all' );
1792
-		$this->loader->add_action( 'wp_ajax_wl_sample_data_create', $this->sample_data_ajax_adapter, 'create' );
1793
-		$this->loader->add_action( 'wp_ajax_wl_sample_data_delete', $this->sample_data_ajax_adapter, 'delete' );
1794
-		/**
1795
-		 * @since 3.26.0
1796
-		 */
1797
-		if ( apply_filters( 'wl_feature__enable__post_excerpt', true ) ) {
1798
-			$excerpt_adapter = new Post_Excerpt_Meta_Box_Adapter();
1799
-			$this->loader->add_action( 'do_meta_boxes', $excerpt_adapter, 'replace_post_excerpt_meta_box' );
1800
-			// Adding Rest route for the post excerpt
1801
-			Post_Excerpt_Rest_Controller::register_routes();
1802
-		}
1803
-
1804
-		$this->loader->add_action( 'update_user_metadata', $this->user_service, 'update_user_metadata', 10, 5 );
1805
-		$this->loader->add_action( 'delete_user_metadata', $this->user_service, 'delete_user_metadata', 10, 5 );
1806
-
1807
-		// Handle the autocomplete request.
1808
-		add_action( 'wp_ajax_wl_autocomplete', array(
1809
-			$this->autocomplete_adapter,
1810
-			'wl_autocomplete',
1811
-		) );
1812
-		add_action( 'wp_ajax_nopriv_wl_autocomplete', array(
1813
-			$this->autocomplete_adapter,
1814
-			'wl_autocomplete',
1815
-		) );
1816
-
1817
-		// Hooks to restrict multisite super admin from manipulating entity types.
1818
-		if ( is_multisite() ) {
1819
-			$this->loader->add_filter( 'map_meta_cap', $this->entity_type_admin_page, 'restrict_super_admin', 10, 4 );
1820
-		}
1821
-
1822
-		$deactivator_feedback = new Wordlift_Deactivator_Feedback( $this->configuration_service );
1823
-
1824
-		add_action( 'admin_footer', array( $deactivator_feedback, 'render_feedback_popup' ) );
1825
-		add_action( 'admin_enqueue_scripts', array( $deactivator_feedback, 'enqueue_popup_scripts' ) );
1826
-		add_action( 'wp_ajax_wl_deactivation_feedback', array( $deactivator_feedback, 'wl_deactivation_feedback' ) );
1827
-
1828
-		/**
1829
-		 * Always allow the `wordlift/classification` block.
1830
-		 *
1831
-		 * @since 3.23.0
1832
-		 */
1833
-		add_filter( 'allowed_block_types', function ( $value ) {
1834
-
1835
-			if ( true === $value ) {
1836
-				return $value;
1837
-			}
1838
-
1839
-			return array_merge( (array) $value, array( 'wordlift/classification' ) );
1840
-		}, PHP_INT_MAX );
1841
-
1842
-		/**
1843
-		 * @since 3.27.7
1844
-		 * @see https://github.com/insideout10/wordlift-plugin/issues/1214
1845
-		 */
1846
-		new Top_Entities();
1847
-	}
1848
-
1849
-	/**
1850
-	 * Register all of the hooks related to the public-facing functionality
1851
-	 * of the plugin.
1852
-	 *
1853
-	 * @since    1.0.0
1854
-	 * @access   private
1855
-	 */
1856
-	private function define_public_hooks() {
1857
-
1858
-		$plugin_public = new Wordlift_Public( $this->get_plugin_name(), $this->get_version() );
1859
-
1860
-		// Register the entity post type.
1861
-		$this->loader->add_action( 'init', $this->entity_post_type_service, 'register' );
1862
-
1863
-		// Bind the link generation and handling hooks to the entity link service.
1864
-		$this->loader->add_filter( 'post_type_link', $this->entity_link_service, 'post_type_link', 10, 4 );
1865
-		$this->loader->add_action( 'pre_get_posts', $this->entity_link_service, 'pre_get_posts', PHP_INT_MAX, 1 );
1866
-		// $this->loader->add_filter( 'wp_unique_post_slug_is_bad_flat_slug', $this->entity_link_service, 'wp_unique_post_slug_is_bad_flat_slug', 10, 3 );
1867
-		// $this->loader->add_filter( 'wp_unique_post_slug_is_bad_hierarchical_slug', $this->entity_link_service, 'wp_unique_post_slug_is_bad_hierarchical_slug', 10, 4 );
1868
-
1869
-		$this->loader->add_action( 'wp_enqueue_scripts', $plugin_public, 'enqueue_styles' );
1870
-		$this->loader->add_action( 'wp_enqueue_scripts', $plugin_public, 'enqueue_scripts' );
1871
-		$this->loader->add_action( 'wp_enqueue_scripts', $this->context_cards_service, 'enqueue_scripts' );
1872
-
1873
-		// Registering Faq_Content_Filter service used for removing faq question and answer tags from the html.
1874
-		$this->loader->add_filter( 'the_content', $this->faq_content_filter_service, 'remove_all_faq_question_and_answer_tags' );
1875
-		// Hook the content filter service to add entity links.
1876
-		if ( ! defined( 'WL_DISABLE_CONTENT_FILTER' ) || ! WL_DISABLE_CONTENT_FILTER ) {
1877
-			$this->loader->add_filter( 'the_content', $this->content_filter_service, 'the_content' );
1878
-		}
1879
-
1880
-		// Hook the AJAX wl_timeline action to the Timeline service.
1881
-		$this->loader->add_action( 'wp_ajax_nopriv_wl_timeline', $this->timeline_service, 'ajax_timeline' );
1882
-
1883
-		// Hook the ShareThis service.
1884
-		$this->loader->add_filter( 'the_content', $this->sharethis_service, 'the_content', 99 );
1885
-		$this->loader->add_filter( 'the_excerpt', $this->sharethis_service, 'the_excerpt', 99 );
1886
-
1887
-		// Hook the AJAX wl_jsonld action to the JSON-LD service.
1888
-		$this->loader->add_action( 'wp_ajax_nopriv_wl_jsonld', $this->jsonld_service, 'get' );
1889
-
1890
-		// Hook the `pre_get_posts` action to the `Wordlift_Category_Taxonomy_Service`
1891
-		// in order to tweak WP's `WP_Query` to include entities in queries related
1892
-		// to categories.
1893
-		$this->loader->add_action( 'pre_get_posts', $this->category_taxonomy_service, 'pre_get_posts', 10, 1 );
1894
-
1895
-		/*
1759
+        // $this->loader->add_filter( 'plugin_action_links_wordlift/wordlift.php', $this->analytics_settings_page_action_link, 'action_links', 10, 1 );
1760
+
1761
+        // Hook the AJAX `wl_publisher` action name.
1762
+        $this->loader->add_action( 'wp_ajax_wl_publisher', $this->publisher_ajax_adapter, 'publisher' );
1763
+
1764
+        // Hook row actions for the entity type list admin.
1765
+        $this->loader->add_filter( 'wl_entity_type_row_actions', $this->entity_type_admin_page, 'wl_entity_type_row_actions', 10, 2 );
1766
+
1767
+        /** Ajax actions. */
1768
+        $this->loader->add_action( 'wp_ajax_wl_google_analytics_export', $this->google_analytics_export_service, 'export' );
1769
+
1770
+        // Hook capabilities manipulation to allow access to entity type admin
1771
+        // page  on WordPress versions before 4.7.
1772
+        global $wp_version;
1773
+        if ( version_compare( $wp_version, '4.7', '<' ) ) {
1774
+            $this->loader->add_filter( 'map_meta_cap', $this->entity_type_admin_page, 'enable_admin_access_pre_47', 10, 4 );
1775
+        }
1776
+
1777
+        $this->loader->add_action( 'wl_async_wl_run_sparql_query', $this->sparql_service, 'run_sparql_query', 10, 1 );
1778
+
1779
+        /** Adapters. */
1780
+        $this->loader->add_filter( 'mce_external_plugins', $this->tinymce_adapter, 'mce_external_plugins', 10, 1 );
1781
+        /**
1782
+         * Disabling Faq temporarily.
1783
+         * Load the tinymce editor button on the tool bar.
1784
+         * @since 3.26.0
1785
+         */
1786
+        //$this->loader->add_filter( 'tiny_mce_before_init', $this->faq_tinymce_adapter, 'register_custom_tags' );
1787
+        //$this->loader->add_filter( 'mce_buttons', $this->faq_tinymce_adapter, 'register_faq_toolbar_button', 10, 1 );
1788
+        //$this->loader->add_filter( 'mce_external_plugins', $this->faq_tinymce_adapter, 'register_faq_tinymce_plugin', 10, 1 );
1789
+
1790
+
1791
+        $this->loader->add_action( 'wp_ajax_wl_relation_rebuild_process_all', $this->relation_rebuild_adapter, 'process_all' );
1792
+        $this->loader->add_action( 'wp_ajax_wl_sample_data_create', $this->sample_data_ajax_adapter, 'create' );
1793
+        $this->loader->add_action( 'wp_ajax_wl_sample_data_delete', $this->sample_data_ajax_adapter, 'delete' );
1794
+        /**
1795
+         * @since 3.26.0
1796
+         */
1797
+        if ( apply_filters( 'wl_feature__enable__post_excerpt', true ) ) {
1798
+            $excerpt_adapter = new Post_Excerpt_Meta_Box_Adapter();
1799
+            $this->loader->add_action( 'do_meta_boxes', $excerpt_adapter, 'replace_post_excerpt_meta_box' );
1800
+            // Adding Rest route for the post excerpt
1801
+            Post_Excerpt_Rest_Controller::register_routes();
1802
+        }
1803
+
1804
+        $this->loader->add_action( 'update_user_metadata', $this->user_service, 'update_user_metadata', 10, 5 );
1805
+        $this->loader->add_action( 'delete_user_metadata', $this->user_service, 'delete_user_metadata', 10, 5 );
1806
+
1807
+        // Handle the autocomplete request.
1808
+        add_action( 'wp_ajax_wl_autocomplete', array(
1809
+            $this->autocomplete_adapter,
1810
+            'wl_autocomplete',
1811
+        ) );
1812
+        add_action( 'wp_ajax_nopriv_wl_autocomplete', array(
1813
+            $this->autocomplete_adapter,
1814
+            'wl_autocomplete',
1815
+        ) );
1816
+
1817
+        // Hooks to restrict multisite super admin from manipulating entity types.
1818
+        if ( is_multisite() ) {
1819
+            $this->loader->add_filter( 'map_meta_cap', $this->entity_type_admin_page, 'restrict_super_admin', 10, 4 );
1820
+        }
1821
+
1822
+        $deactivator_feedback = new Wordlift_Deactivator_Feedback( $this->configuration_service );
1823
+
1824
+        add_action( 'admin_footer', array( $deactivator_feedback, 'render_feedback_popup' ) );
1825
+        add_action( 'admin_enqueue_scripts', array( $deactivator_feedback, 'enqueue_popup_scripts' ) );
1826
+        add_action( 'wp_ajax_wl_deactivation_feedback', array( $deactivator_feedback, 'wl_deactivation_feedback' ) );
1827
+
1828
+        /**
1829
+         * Always allow the `wordlift/classification` block.
1830
+         *
1831
+         * @since 3.23.0
1832
+         */
1833
+        add_filter( 'allowed_block_types', function ( $value ) {
1834
+
1835
+            if ( true === $value ) {
1836
+                return $value;
1837
+            }
1838
+
1839
+            return array_merge( (array) $value, array( 'wordlift/classification' ) );
1840
+        }, PHP_INT_MAX );
1841
+
1842
+        /**
1843
+         * @since 3.27.7
1844
+         * @see https://github.com/insideout10/wordlift-plugin/issues/1214
1845
+         */
1846
+        new Top_Entities();
1847
+    }
1848
+
1849
+    /**
1850
+     * Register all of the hooks related to the public-facing functionality
1851
+     * of the plugin.
1852
+     *
1853
+     * @since    1.0.0
1854
+     * @access   private
1855
+     */
1856
+    private function define_public_hooks() {
1857
+
1858
+        $plugin_public = new Wordlift_Public( $this->get_plugin_name(), $this->get_version() );
1859
+
1860
+        // Register the entity post type.
1861
+        $this->loader->add_action( 'init', $this->entity_post_type_service, 'register' );
1862
+
1863
+        // Bind the link generation and handling hooks to the entity link service.
1864
+        $this->loader->add_filter( 'post_type_link', $this->entity_link_service, 'post_type_link', 10, 4 );
1865
+        $this->loader->add_action( 'pre_get_posts', $this->entity_link_service, 'pre_get_posts', PHP_INT_MAX, 1 );
1866
+        // $this->loader->add_filter( 'wp_unique_post_slug_is_bad_flat_slug', $this->entity_link_service, 'wp_unique_post_slug_is_bad_flat_slug', 10, 3 );
1867
+        // $this->loader->add_filter( 'wp_unique_post_slug_is_bad_hierarchical_slug', $this->entity_link_service, 'wp_unique_post_slug_is_bad_hierarchical_slug', 10, 4 );
1868
+
1869
+        $this->loader->add_action( 'wp_enqueue_scripts', $plugin_public, 'enqueue_styles' );
1870
+        $this->loader->add_action( 'wp_enqueue_scripts', $plugin_public, 'enqueue_scripts' );
1871
+        $this->loader->add_action( 'wp_enqueue_scripts', $this->context_cards_service, 'enqueue_scripts' );
1872
+
1873
+        // Registering Faq_Content_Filter service used for removing faq question and answer tags from the html.
1874
+        $this->loader->add_filter( 'the_content', $this->faq_content_filter_service, 'remove_all_faq_question_and_answer_tags' );
1875
+        // Hook the content filter service to add entity links.
1876
+        if ( ! defined( 'WL_DISABLE_CONTENT_FILTER' ) || ! WL_DISABLE_CONTENT_FILTER ) {
1877
+            $this->loader->add_filter( 'the_content', $this->content_filter_service, 'the_content' );
1878
+        }
1879
+
1880
+        // Hook the AJAX wl_timeline action to the Timeline service.
1881
+        $this->loader->add_action( 'wp_ajax_nopriv_wl_timeline', $this->timeline_service, 'ajax_timeline' );
1882
+
1883
+        // Hook the ShareThis service.
1884
+        $this->loader->add_filter( 'the_content', $this->sharethis_service, 'the_content', 99 );
1885
+        $this->loader->add_filter( 'the_excerpt', $this->sharethis_service, 'the_excerpt', 99 );
1886
+
1887
+        // Hook the AJAX wl_jsonld action to the JSON-LD service.
1888
+        $this->loader->add_action( 'wp_ajax_nopriv_wl_jsonld', $this->jsonld_service, 'get' );
1889
+
1890
+        // Hook the `pre_get_posts` action to the `Wordlift_Category_Taxonomy_Service`
1891
+        // in order to tweak WP's `WP_Query` to include entities in queries related
1892
+        // to categories.
1893
+        $this->loader->add_action( 'pre_get_posts', $this->category_taxonomy_service, 'pre_get_posts', 10, 1 );
1894
+
1895
+        /*
1896 1896
 		 * Hook the `pre_get_posts` action to the `Wordlift_Entity_Page_Service`
1897 1897
 		 * in order to tweak WP's `WP_Query` to show event related entities in reverse
1898 1898
 		 * order of start time.
1899 1899
 		 */
1900
-		$this->loader->add_action( 'pre_get_posts', $this->entity_page_service, 'pre_get_posts', 10, 1 );
1901
-
1902
-		$this->loader->add_action( 'wl_async_wl_run_sparql_query', $this->sparql_service, 'run_sparql_query', 10, 1 );
1903
-
1904
-		// This hook have to run before the rating service, as otherwise the post might not be a proper entity when rating is done.
1905
-		$this->loader->add_action( 'save_post', $this->entity_type_adapter, 'save_post', 9, 3 );
1906
-
1907
-		// Analytics Script Frontend.
1908
-		if ( $this->configuration_service->is_analytics_enable() ) {
1909
-			$this->loader->add_action( 'wp_enqueue_scripts', $this->analytics_connect, 'enqueue_scripts', 10 );
1910
-		}
1911
-
1912
-	}
1913
-
1914
-	/**
1915
-	 * Run the loader to execute all of the hooks with WordPress.
1916
-	 *
1917
-	 * @since    1.0.0
1918
-	 */
1919
-	public function run() {
1920
-		$this->loader->run();
1921
-	}
1922
-
1923
-	/**
1924
-	 * The name of the plugin used to uniquely identify it within the context of
1925
-	 * WordPress and to define internationalization functionality.
1926
-	 *
1927
-	 * @return    string    The name of the plugin.
1928
-	 * @since     1.0.0
1929
-	 */
1930
-	public function get_plugin_name() {
1931
-		return $this->plugin_name;
1932
-	}
1933
-
1934
-	/**
1935
-	 * The reference to the class that orchestrates the hooks with the plugin.
1936
-	 *
1937
-	 * @return    Wordlift_Loader    Orchestrates the hooks of the plugin.
1938
-	 * @since     1.0.0
1939
-	 */
1940
-	public function get_loader() {
1941
-		return $this->loader;
1942
-	}
1943
-
1944
-	/**
1945
-	 * Retrieve the version number of the plugin.
1946
-	 *
1947
-	 * @return    string    The version number of the plugin.
1948
-	 * @since     1.0.0
1949
-	 */
1950
-	public function get_version() {
1951
-		return $this->version;
1952
-	}
1953
-
1954
-	/**
1955
-	 * Load dependencies for WP-CLI.
1956
-	 *
1957
-	 * @throws Exception
1958
-	 * @since 3.18.0
1959
-	 */
1960
-	private function load_cli_dependencies() {
1961
-
1962
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'cli/class-wordlift-push-reference-data-command.php';
1963
-
1964
-		$push_reference_data_command = new Wordlift_Push_Reference_Data_Command( $this->relation_service, $this->entity_service, $this->sparql_service, $this->configuration_service, $this->entity_type_service );
1965
-
1966
-		WP_CLI::add_command( 'wl references push', $push_reference_data_command );
1967
-
1968
-	}
1969
-
1970
-	/**
1971
-	 * Get the {@link \Wordlift_Dashboard_Service} to allow others to use its functions.
1972
-	 *
1973
-	 * @return \Wordlift_Dashboard_Service The {@link \Wordlift_Dashboard_Service} instance.
1974
-	 * @since 3.20.0
1975
-	 */
1976
-	public function get_dashboard_service() {
1977
-
1978
-		return $this->dashboard_service;
1979
-	}
1980
-
1981
-	public function add_wl_enabled_blocks() {
1982
-		/**
1983
-		 * Filter: wl_feature__enable__blocks.
1984
-		 *
1985
-		 * @param bool whether the blocks needed to be registered, defaults to true.
1986
-		 *
1987
-		 * @return bool
1988
-		 * @since 3.27.6
1989
-		 */
1990
-
1991
-		wp_register_script( 'wl_enabled_blocks', false );
1992
-
1993
-		$enabled_blocks = array( 'wordlift/products-navigator' );
1994
-
1995
-		if ( apply_filters( 'wl_feature__enable__blocks', true ) ) {
1996
-			// To intimate JS
1997
-			$enabled_blocks = array_merge( $enabled_blocks, array(
1998
-				'wordlift/navigator',
1999
-				'wordlift/chord',
2000
-				'wordlift/geomap',
2001
-				'wordlift/timeline',
2002
-				'wordlift/cloud',
2003
-				'wordlift/vocabulary',
2004
-				'wordlift/faceted-search'
2005
-			) );
2006
-		}
2007
-
2008
-		wp_localize_script( 'wl_enabled_blocks', 'wlEnabledBlocks', $enabled_blocks );
2009
-		wp_enqueue_script( 'wl_enabled_blocks' );
2010
-	}
1900
+        $this->loader->add_action( 'pre_get_posts', $this->entity_page_service, 'pre_get_posts', 10, 1 );
1901
+
1902
+        $this->loader->add_action( 'wl_async_wl_run_sparql_query', $this->sparql_service, 'run_sparql_query', 10, 1 );
1903
+
1904
+        // This hook have to run before the rating service, as otherwise the post might not be a proper entity when rating is done.
1905
+        $this->loader->add_action( 'save_post', $this->entity_type_adapter, 'save_post', 9, 3 );
1906
+
1907
+        // Analytics Script Frontend.
1908
+        if ( $this->configuration_service->is_analytics_enable() ) {
1909
+            $this->loader->add_action( 'wp_enqueue_scripts', $this->analytics_connect, 'enqueue_scripts', 10 );
1910
+        }
1911
+
1912
+    }
1913
+
1914
+    /**
1915
+     * Run the loader to execute all of the hooks with WordPress.
1916
+     *
1917
+     * @since    1.0.0
1918
+     */
1919
+    public function run() {
1920
+        $this->loader->run();
1921
+    }
1922
+
1923
+    /**
1924
+     * The name of the plugin used to uniquely identify it within the context of
1925
+     * WordPress and to define internationalization functionality.
1926
+     *
1927
+     * @return    string    The name of the plugin.
1928
+     * @since     1.0.0
1929
+     */
1930
+    public function get_plugin_name() {
1931
+        return $this->plugin_name;
1932
+    }
1933
+
1934
+    /**
1935
+     * The reference to the class that orchestrates the hooks with the plugin.
1936
+     *
1937
+     * @return    Wordlift_Loader    Orchestrates the hooks of the plugin.
1938
+     * @since     1.0.0
1939
+     */
1940
+    public function get_loader() {
1941
+        return $this->loader;
1942
+    }
1943
+
1944
+    /**
1945
+     * Retrieve the version number of the plugin.
1946
+     *
1947
+     * @return    string    The version number of the plugin.
1948
+     * @since     1.0.0
1949
+     */
1950
+    public function get_version() {
1951
+        return $this->version;
1952
+    }
1953
+
1954
+    /**
1955
+     * Load dependencies for WP-CLI.
1956
+     *
1957
+     * @throws Exception
1958
+     * @since 3.18.0
1959
+     */
1960
+    private function load_cli_dependencies() {
1961
+
1962
+        require_once plugin_dir_path( dirname( __FILE__ ) ) . 'cli/class-wordlift-push-reference-data-command.php';
1963
+
1964
+        $push_reference_data_command = new Wordlift_Push_Reference_Data_Command( $this->relation_service, $this->entity_service, $this->sparql_service, $this->configuration_service, $this->entity_type_service );
1965
+
1966
+        WP_CLI::add_command( 'wl references push', $push_reference_data_command );
1967
+
1968
+    }
1969
+
1970
+    /**
1971
+     * Get the {@link \Wordlift_Dashboard_Service} to allow others to use its functions.
1972
+     *
1973
+     * @return \Wordlift_Dashboard_Service The {@link \Wordlift_Dashboard_Service} instance.
1974
+     * @since 3.20.0
1975
+     */
1976
+    public function get_dashboard_service() {
1977
+
1978
+        return $this->dashboard_service;
1979
+    }
1980
+
1981
+    public function add_wl_enabled_blocks() {
1982
+        /**
1983
+         * Filter: wl_feature__enable__blocks.
1984
+         *
1985
+         * @param bool whether the blocks needed to be registered, defaults to true.
1986
+         *
1987
+         * @return bool
1988
+         * @since 3.27.6
1989
+         */
1990
+
1991
+        wp_register_script( 'wl_enabled_blocks', false );
1992
+
1993
+        $enabled_blocks = array( 'wordlift/products-navigator' );
1994
+
1995
+        if ( apply_filters( 'wl_feature__enable__blocks', true ) ) {
1996
+            // To intimate JS
1997
+            $enabled_blocks = array_merge( $enabled_blocks, array(
1998
+                'wordlift/navigator',
1999
+                'wordlift/chord',
2000
+                'wordlift/geomap',
2001
+                'wordlift/timeline',
2002
+                'wordlift/cloud',
2003
+                'wordlift/vocabulary',
2004
+                'wordlift/faceted-search'
2005
+            ) );
2006
+        }
2007
+
2008
+        wp_localize_script( 'wl_enabled_blocks', 'wlEnabledBlocks', $enabled_blocks );
2009
+        wp_enqueue_script( 'wl_enabled_blocks' );
2010
+    }
2011 2011
 
2012 2012
 }
Please login to merge, or discard this patch.
Spacing   +346 added lines, -346 removed lines patch added patch discarded remove patch
@@ -757,7 +757,7 @@  discard block
 block discarded – undo
757 757
 		$this->define_public_hooks();
758 758
 
759 759
 		// If we're in `WP_CLI` load the related files.
760
-		if ( class_exists( 'WP_CLI' ) ) {
760
+		if (class_exists('WP_CLI')) {
761 761
 			$this->load_cli_dependencies();
762 762
 		}
763 763
 
@@ -798,381 +798,381 @@  discard block
 block discarded – undo
798 798
 		 * The class responsible for orchestrating the actions and filters of the
799 799
 		 * core plugin.
800 800
 		 */
801
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-loader.php';
801
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-loader.php';
802 802
 
803 803
 		// The class responsible for plugin uninstall.
804
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-deactivator-feedback.php';
804
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-deactivator-feedback.php';
805 805
 
806 806
 		/**
807 807
 		 * The class responsible for defining internationalization functionality
808 808
 		 * of the plugin.
809 809
 		 */
810
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-i18n.php';
810
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-i18n.php';
811 811
 
812 812
 		/**
813 813
 		 * WordLift's supported languages.
814 814
 		 */
815
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-languages.php';
815
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-languages.php';
816 816
 
817 817
 		/**
818 818
 		 * WordLift's supported countries.
819 819
 		 */
820
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-countries.php';
820
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-countries.php';
821 821
 
822 822
 		/**
823 823
 		 * Provide support functions to sanitize data.
824 824
 		 */
825
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-sanitizer.php';
825
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-sanitizer.php';
826 826
 
827 827
 		/** Services. */
828
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-log-service.php';
829
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-http-api.php';
830
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-redirect-service.php';
831
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-configuration-service.php';
832
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-entity-post-type-service.php';
833
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-entity-type-service.php';
834
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-entity-link-service.php';
835
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-linked-data-service.php';
836
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-relation-service.php';
837
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-image-service.php';
828
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-log-service.php';
829
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-http-api.php';
830
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-redirect-service.php';
831
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-configuration-service.php';
832
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-entity-post-type-service.php';
833
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-entity-type-service.php';
834
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-entity-link-service.php';
835
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-linked-data-service.php';
836
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-relation-service.php';
837
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-image-service.php';
838 838
 
839 839
 		/**
840 840
 		 * The Query builder.
841 841
 		 */
842
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-query-builder.php';
842
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-query-builder.php';
843 843
 
844 844
 		/**
845 845
 		 * The Schema service.
846 846
 		 */
847
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-schema-service.php';
847
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-schema-service.php';
848 848
 
849 849
 		/**
850 850
 		 * The schema:url property service.
851 851
 		 */
852
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-property-service.php';
853
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-schema-url-property-service.php';
852
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-property-service.php';
853
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-schema-url-property-service.php';
854 854
 
855 855
 		/**
856 856
 		 * The UI service.
857 857
 		 */
858
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-ui-service.php';
858
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-ui-service.php';
859 859
 
860 860
 		/**
861 861
 		 * The Thumbnail service.
862 862
 		 */
863
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-thumbnail-service.php';
863
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-thumbnail-service.php';
864 864
 
865 865
 		/**
866 866
 		 * The Entity Types Taxonomy service.
867 867
 		 */
868
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-entity-type-taxonomy-service.php';
868
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-entity-type-taxonomy-service.php';
869 869
 
870 870
 		/**
871 871
 		 * The Entity service.
872 872
 		 */
873
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-entity-uri-service.php';
874
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-entity-service.php';
873
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-entity-uri-service.php';
874
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-entity-service.php';
875 875
 
876 876
 		// Add the entity rating service.
877
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-rating-service.php';
877
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-rating-service.php';
878 878
 
879 879
 		/**
880 880
 		 * The User service.
881 881
 		 */
882
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-user-service.php';
882
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-user-service.php';
883 883
 
884 884
 		/**
885 885
 		 * The Timeline service.
886 886
 		 */
887
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-timeline-service.php';
887
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-timeline-service.php';
888 888
 
889 889
 		/**
890 890
 		 * The Topic Taxonomy service.
891 891
 		 */
892
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-topic-taxonomy-service.php';
892
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-topic-taxonomy-service.php';
893 893
 
894 894
 		/**
895 895
 		 * The SPARQL service.
896 896
 		 */
897
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-sparql-service.php';
897
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-sparql-service.php';
898 898
 
899 899
 		/**
900 900
 		 * The WordLift import service.
901 901
 		 */
902
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-import-service.php';
902
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-import-service.php';
903 903
 
904 904
 		/**
905 905
 		 * The WordLift URI service.
906 906
 		 */
907
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-uri-service.php';
908
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-property-factory.php';
909
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-sample-data-service.php';
907
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-uri-service.php';
908
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-property-factory.php';
909
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-sample-data-service.php';
910 910
 
911 911
 		/**
912 912
 		 * The WordLift rebuild service, used to rebuild the remote dataset using the local data.
913 913
 		 */
914
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/rebuild/class-wordlift-listable.php';
915
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/rebuild/class-wordlift-rebuild-service.php';
916
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/rebuild/class-wordlift-reference-rebuild-service.php';
917
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/rebuild/class-wordlift-relation-rebuild-service.php';
918
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/rebuild/class-wordlift-relation-rebuild-adapter.php';
914
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/rebuild/class-wordlift-listable.php';
915
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/rebuild/class-wordlift-rebuild-service.php';
916
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/rebuild/class-wordlift-reference-rebuild-service.php';
917
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/rebuild/class-wordlift-relation-rebuild-service.php';
918
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/rebuild/class-wordlift-relation-rebuild-adapter.php';
919 919
 
920
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/properties/class-wordlift-property-getter-factory.php';
921
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-attachment-service.php';
920
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/properties/class-wordlift-property-getter-factory.php';
921
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-attachment-service.php';
922 922
 
923 923
 		/**
924 924
 		 * Load the converters.
925 925
 		 */
926
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/intf-wordlift-post-converter.php';
927
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-abstract-post-to-jsonld-converter.php';
928
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-postid-to-jsonld-converter.php';
929
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-entity-post-to-jsonld-converter.php';
930
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-post-to-jsonld-converter.php';
931
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-jsonld-website-converter.php';
926
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/intf-wordlift-post-converter.php';
927
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-abstract-post-to-jsonld-converter.php';
928
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-postid-to-jsonld-converter.php';
929
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-entity-post-to-jsonld-converter.php';
930
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-post-to-jsonld-converter.php';
931
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-jsonld-website-converter.php';
932 932
 
933 933
 		/**
934 934
 		 * Load cache-related files.
935 935
 		 */
936
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/cache/require.php';
936
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/cache/require.php';
937 937
 
938 938
 		/**
939 939
 		 * Load the content filter.
940 940
 		 */
941
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-content-filter-service.php';
941
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-content-filter-service.php';
942 942
 
943 943
 		/*
944 944
 		 * Load the excerpt helper.
945 945
 		 */
946
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-post-excerpt-helper.php';
946
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-post-excerpt-helper.php';
947 947
 
948 948
 		/**
949 949
 		 * Load the JSON-LD service to publish entities using JSON-LD.s
950 950
 		 *
951 951
 		 * @since 3.8.0
952 952
 		 */
953
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-jsonld-service.php';
953
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-jsonld-service.php';
954 954
 
955 955
 		// The Publisher Service and the AJAX adapter.
956
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-publisher-service.php';
957
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-publisher-ajax-adapter.php';
956
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-publisher-service.php';
957
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-publisher-ajax-adapter.php';
958 958
 
959
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-post-adapter.php';
959
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-post-adapter.php';
960 960
 
961 961
 		/**
962 962
 		 * Load the WordLift key validation service.
963 963
 		 */
964
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-key-validation-service.php';
964
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-key-validation-service.php';
965 965
 
966 966
 		// Load the `Wordlift_Category_Taxonomy_Service` class definition.
967
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-category-taxonomy-service.php';
967
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-category-taxonomy-service.php';
968 968
 
969 969
 		// Load the `Wordlift_Entity_Page_Service` class definition.
970
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-entity-page-service.php';
970
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-entity-page-service.php';
971 971
 
972 972
 		/** Linked Data. */
973
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-storage.php';
974
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-post-meta-storage.php';
975
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-post-property-storage.php';
976
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-post-taxonomy-storage.php';
977
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-post-schema-class-storage.php';
978
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-post-author-storage.php';
979
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-post-meta-uri-storage.php';
980
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-post-image-storage.php';
981
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-post-related-storage.php';
982
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-url-property-storage.php';
983
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/storage/class-wordlift-storage-factory.php';
973
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/linked-data/storage/class-wordlift-storage.php';
974
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/linked-data/storage/class-wordlift-post-meta-storage.php';
975
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/linked-data/storage/class-wordlift-post-property-storage.php';
976
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/linked-data/storage/class-wordlift-post-taxonomy-storage.php';
977
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/linked-data/storage/class-wordlift-post-schema-class-storage.php';
978
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/linked-data/storage/class-wordlift-post-author-storage.php';
979
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/linked-data/storage/class-wordlift-post-meta-uri-storage.php';
980
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/linked-data/storage/class-wordlift-post-image-storage.php';
981
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/linked-data/storage/class-wordlift-post-related-storage.php';
982
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/linked-data/storage/class-wordlift-url-property-storage.php';
983
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/linked-data/storage/class-wordlift-storage-factory.php';
984 984
 
985 985
 		/** Linked Data Rendition. */
986
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/rendition/intf-wordlift-sparql-tuple-rendition.php';
987
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/rendition/class-wordlift-default-sparql-tuple-rendition.php';
988
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/rendition/class-wordlift-address-sparql-tuple-rendition.php';
989
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/linked-data/rendition/class-wordlift-sparql-tuple-rendition-factory.php';
986
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/linked-data/rendition/intf-wordlift-sparql-tuple-rendition.php';
987
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/linked-data/rendition/class-wordlift-default-sparql-tuple-rendition.php';
988
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/linked-data/rendition/class-wordlift-address-sparql-tuple-rendition.php';
989
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/linked-data/rendition/class-wordlift-sparql-tuple-rendition-factory.php';
990 990
 
991 991
 		/** Services. */
992
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-google-analytics-export-service.php';
993
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-api-service.php';
992
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-google-analytics-export-service.php';
993
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-api-service.php';
994 994
 
995 995
 		/** Adapters. */
996
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-tinymce-adapter.php';
997
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-newrelic-adapter.php';
998
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-sample-data-ajax-adapter.php';
999
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-entity-type-adapter.php';
1000
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-wprocket-adapter.php';
996
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-tinymce-adapter.php';
997
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-newrelic-adapter.php';
998
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-sample-data-ajax-adapter.php';
999
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-entity-type-adapter.php';
1000
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-wprocket-adapter.php';
1001 1001
 
1002 1002
 		/** Async Tasks. */
1003
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/wp-async-task/class-wordlift-async-task.php';
1004
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/wp-async-task/class-wordlift-sparql-query-async-task.php';
1005
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/wp-async-task/class-wordlift-push-references-async-task.php';
1003
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/wp-async-task/class-wordlift-async-task.php';
1004
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/wp-async-task/class-wordlift-sparql-query-async-task.php';
1005
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/wp-async-task/class-wordlift-push-references-async-task.php';
1006 1006
 
1007 1007
 		/** Autocomplete. */
1008
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-autocomplete-adapter.php';
1008
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-autocomplete-adapter.php';
1009 1009
 
1010
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-remote-image-service.php';
1010
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-remote-image-service.php';
1011 1011
 
1012 1012
 		/** Analytics */
1013
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/analytics/class-wordlift-analytics-connect.php';
1013
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/analytics/class-wordlift-analytics-connect.php';
1014 1014
 
1015 1015
 		/**
1016 1016
 		 * The class responsible for defining all actions that occur in the admin area.
1017 1017
 		 */
1018
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin.php';
1018
+		require_once plugin_dir_path(dirname(__FILE__)).'admin/class-wordlift-admin.php';
1019 1019
 
1020 1020
 		/**
1021 1021
 		 * The class to customize the entity list admin page.
1022 1022
 		 */
1023
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-entity-list.php';
1023
+		require_once plugin_dir_path(dirname(__FILE__)).'admin/class-wordlift-admin-entity-list.php';
1024 1024
 
1025 1025
 		/**
1026 1026
 		 * The Entity Types Taxonomy Walker (transforms checkboxes into radios).
1027 1027
 		 */
1028 1028
 		global $wp_version;
1029
-		if ( version_compare( $wp_version, '5.3', '<' ) ) {
1030
-			require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-entity-types-taxonomy-walker.php';
1029
+		if (version_compare($wp_version, '5.3', '<')) {
1030
+			require_once plugin_dir_path(dirname(__FILE__)).'admin/class-wordlift-entity-types-taxonomy-walker.php';
1031 1031
 		} else {
1032
-			require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-entity-types-taxonomy-walker-5-3.php';
1032
+			require_once plugin_dir_path(dirname(__FILE__)).'admin/class-wordlift-entity-types-taxonomy-walker-5-3.php';
1033 1033
 		}
1034 1034
 
1035 1035
 		/**
1036 1036
 		 * The Notice service.
1037 1037
 		 */
1038
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-notice-service.php';
1038
+		require_once plugin_dir_path(dirname(__FILE__)).'admin/class-wordlift-notice-service.php';
1039 1039
 
1040 1040
 		/**
1041 1041
 		 * The PrimaShop adapter.
1042 1042
 		 */
1043
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-primashop-adapter.php';
1043
+		require_once plugin_dir_path(dirname(__FILE__)).'admin/class-wordlift-primashop-adapter.php';
1044 1044
 
1045 1045
 		/**
1046 1046
 		 * The WordLift Dashboard service.
1047 1047
 		 */
1048
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-dashboard.php';
1048
+		require_once plugin_dir_path(dirname(__FILE__)).'admin/class-wordlift-admin-dashboard.php';
1049 1049
 
1050 1050
 		/**
1051 1051
 		 * The admin 'Install wizard' page.
1052 1052
 		 */
1053
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-setup.php';
1053
+		require_once plugin_dir_path(dirname(__FILE__)).'admin/class-wordlift-admin-setup.php';
1054 1054
 
1055 1055
 		/**
1056 1056
 		 * The WordLift entity type list admin page controller.
1057 1057
 		 */
1058
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-entity-taxonomy-list-page.php';
1058
+		require_once plugin_dir_path(dirname(__FILE__)).'admin/class-wordlift-admin-entity-taxonomy-list-page.php';
1059 1059
 
1060 1060
 		/**
1061 1061
 		 * The WordLift entity type settings admin page controller.
1062 1062
 		 */
1063
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-entity-type-settings.php';
1063
+		require_once plugin_dir_path(dirname(__FILE__)).'admin/class-wordlift-entity-type-settings.php';
1064 1064
 
1065 1065
 		/**
1066 1066
 		 * The admin 'Download Your Data' page.
1067 1067
 		 */
1068
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-download-your-data-page.php';
1068
+		require_once plugin_dir_path(dirname(__FILE__)).'admin/class-wordlift-download-your-data-page.php';
1069 1069
 
1070 1070
 		/**
1071 1071
 		 * The admin 'WordLift Settings' page.
1072 1072
 		 */
1073
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/elements/intf-wordlift-admin-element.php';
1074
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/elements/class-wordlift-admin-input-element.php';
1075
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/elements/class-wordlift-admin-input-radio-element.php';
1076
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/elements/class-wordlift-admin-select-element.php';
1077
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/elements/class-wordlift-admin-select2-element.php';
1078
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/elements/class-wordlift-admin-language-select-element.php';
1079
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/elements/class-wordlift-admin-country-select-element.php';
1080
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/elements/class-wordlift-admin-tabs-element.php';
1081
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/elements/class-wordlift-admin-author-element.php';
1082
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/elements/class-wordlift-admin-publisher-element.php';
1083
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-page.php';
1084
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-settings-page.php';
1085
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-settings-analytics-page.php';
1086
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-settings-page-action-link.php';
1087
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-settings-analytics-page-action-link.php';
1073
+		require_once plugin_dir_path(dirname(__FILE__)).'admin/elements/intf-wordlift-admin-element.php';
1074
+		require_once plugin_dir_path(dirname(__FILE__)).'admin/elements/class-wordlift-admin-input-element.php';
1075
+		require_once plugin_dir_path(dirname(__FILE__)).'admin/elements/class-wordlift-admin-input-radio-element.php';
1076
+		require_once plugin_dir_path(dirname(__FILE__)).'admin/elements/class-wordlift-admin-select-element.php';
1077
+		require_once plugin_dir_path(dirname(__FILE__)).'admin/elements/class-wordlift-admin-select2-element.php';
1078
+		require_once plugin_dir_path(dirname(__FILE__)).'admin/elements/class-wordlift-admin-language-select-element.php';
1079
+		require_once plugin_dir_path(dirname(__FILE__)).'admin/elements/class-wordlift-admin-country-select-element.php';
1080
+		require_once plugin_dir_path(dirname(__FILE__)).'admin/elements/class-wordlift-admin-tabs-element.php';
1081
+		require_once plugin_dir_path(dirname(__FILE__)).'admin/elements/class-wordlift-admin-author-element.php';
1082
+		require_once plugin_dir_path(dirname(__FILE__)).'admin/elements/class-wordlift-admin-publisher-element.php';
1083
+		require_once plugin_dir_path(dirname(__FILE__)).'admin/class-wordlift-admin-page.php';
1084
+		require_once plugin_dir_path(dirname(__FILE__)).'admin/class-wordlift-admin-settings-page.php';
1085
+		require_once plugin_dir_path(dirname(__FILE__)).'admin/class-wordlift-admin-settings-analytics-page.php';
1086
+		require_once plugin_dir_path(dirname(__FILE__)).'admin/class-wordlift-admin-settings-page-action-link.php';
1087
+		require_once plugin_dir_path(dirname(__FILE__)).'admin/class-wordlift-admin-settings-analytics-page-action-link.php';
1088 1088
 
1089 1089
 		/** Admin Pages */
1090
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-user-profile-page.php';
1091
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-status-page.php';
1092
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-search-rankings-page.php';
1093
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-entity-type-admin-service.php';
1090
+		require_once plugin_dir_path(dirname(__FILE__)).'admin/class-wordlift-admin-user-profile-page.php';
1091
+		require_once plugin_dir_path(dirname(__FILE__)).'admin/class-wordlift-admin-status-page.php';
1092
+		require_once plugin_dir_path(dirname(__FILE__)).'admin/class-wordlift-admin-search-rankings-page.php';
1093
+		require_once plugin_dir_path(dirname(__FILE__)).'admin/class-wordlift-entity-type-admin-service.php';
1094 1094
 
1095 1095
 		/**
1096 1096
 		 * The class responsible for defining all actions that occur in the public-facing
1097 1097
 		 * side of the site.
1098 1098
 		 */
1099
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-public.php';
1099
+		require_once plugin_dir_path(dirname(__FILE__)).'public/class-wordlift-public.php';
1100 1100
 
1101 1101
 		/**
1102 1102
 		 * The shortcode abstract class.
1103 1103
 		 */
1104
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-shortcode.php';
1104
+		require_once plugin_dir_path(dirname(__FILE__)).'public/class-wordlift-shortcode.php';
1105 1105
 
1106 1106
 		/**
1107 1107
 		 * The Timeline shortcode.
1108 1108
 		 */
1109
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-timeline-shortcode.php';
1109
+		require_once plugin_dir_path(dirname(__FILE__)).'public/class-wordlift-timeline-shortcode.php';
1110 1110
 
1111 1111
 		/**
1112 1112
 		 * The Navigator shortcode.
1113 1113
 		 */
1114
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-navigator-shortcode.php';
1114
+		require_once plugin_dir_path(dirname(__FILE__)).'public/class-wordlift-navigator-shortcode.php';
1115 1115
 
1116 1116
 		/**
1117 1117
 		 * The Products Navigator shortcode.
1118 1118
 		 */
1119
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-products-navigator-shortcode.php';
1119
+		require_once plugin_dir_path(dirname(__FILE__)).'public/class-wordlift-products-navigator-shortcode.php';
1120 1120
 
1121 1121
 		/**
1122 1122
 		 * The chord shortcode.
1123 1123
 		 */
1124
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-chord-shortcode.php';
1124
+		require_once plugin_dir_path(dirname(__FILE__)).'public/class-wordlift-chord-shortcode.php';
1125 1125
 
1126 1126
 		/**
1127 1127
 		 * The geomap shortcode.
1128 1128
 		 */
1129
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-geomap-shortcode.php';
1129
+		require_once plugin_dir_path(dirname(__FILE__)).'public/class-wordlift-geomap-shortcode.php';
1130 1130
 
1131 1131
 		/**
1132 1132
 		 * The entity cloud shortcode.
1133 1133
 		 */
1134
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-related-entities-cloud-shortcode.php';
1134
+		require_once plugin_dir_path(dirname(__FILE__)).'public/class-wordlift-related-entities-cloud-shortcode.php';
1135 1135
 
1136 1136
 		/**
1137 1137
 		 * The entity glossary shortcode.
1138 1138
 		 */
1139
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-alphabet-service.php';
1140
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-vocabulary-shortcode.php';
1139
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-alphabet-service.php';
1140
+		require_once plugin_dir_path(dirname(__FILE__)).'public/class-wordlift-vocabulary-shortcode.php';
1141 1141
 
1142 1142
 		/**
1143 1143
 		 * Faceted Search shortcode.
1144 1144
 		 */
1145
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-faceted-search-shortcode.php';
1145
+		require_once plugin_dir_path(dirname(__FILE__)).'public/class-wordlift-faceted-search-shortcode.php';
1146 1146
 
1147 1147
 		/**
1148 1148
 		 * The ShareThis service.
1149 1149
 		 */
1150
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-sharethis-service.php';
1150
+		require_once plugin_dir_path(dirname(__FILE__)).'public/class-wordlift-sharethis-service.php';
1151 1151
 
1152 1152
 		/**
1153 1153
 		 * The SEO service.
1154 1154
 		 */
1155
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-seo-service.php';
1155
+		require_once plugin_dir_path(dirname(__FILE__)).'public/class-wordlift-seo-service.php';
1156 1156
 
1157 1157
 		/**
1158 1158
 		 * The AMP service.
1159 1159
 		 */
1160
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-amp-service.php';
1160
+		require_once plugin_dir_path(dirname(__FILE__)).'public/class-wordlift-amp-service.php';
1161 1161
 
1162 1162
 		/** Widgets */
1163
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-widget.php';
1164
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-related-entities-cloud-widget.php';
1165
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-context-cards.php';
1163
+		require_once plugin_dir_path(dirname(__FILE__)).'public/class-wordlift-widget.php';
1164
+		require_once plugin_dir_path(dirname(__FILE__)).'public/class-wordlift-related-entities-cloud-widget.php';
1165
+		require_once plugin_dir_path(dirname(__FILE__)).'public/class-wordlift-context-cards.php';
1166 1166
 
1167 1167
 		/*
1168 1168
 		 * Schema.org Services.
1169 1169
 		 *
1170 1170
 		 * @see https://github.com/insideout10/wordlift-plugin/issues/835
1171 1171
 		 */
1172
-		if ( WL_ALL_ENTITY_TYPES ) {
1173
-			require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/schemaorg/class-wordlift-schemaorg-sync-service.php';
1174
-			require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/schemaorg/class-wordlift-schemaorg-property-service.php';
1175
-			require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/schemaorg/class-wordlift-schemaorg-class-service.php';
1172
+		if (WL_ALL_ENTITY_TYPES) {
1173
+			require_once plugin_dir_path(dirname(__FILE__)).'includes/schemaorg/class-wordlift-schemaorg-sync-service.php';
1174
+			require_once plugin_dir_path(dirname(__FILE__)).'includes/schemaorg/class-wordlift-schemaorg-property-service.php';
1175
+			require_once plugin_dir_path(dirname(__FILE__)).'includes/schemaorg/class-wordlift-schemaorg-class-service.php';
1176 1176
 			new Wordlift_Schemaorg_Sync_Service();
1177 1177
 			$schemaorg_property_service = new Wordlift_Schemaorg_Property_Service();
1178 1178
 			new Wordlift_Schemaorg_Class_Service();
@@ -1184,25 +1184,25 @@  discard block
 block discarded – undo
1184 1184
 
1185 1185
 		// Instantiate a global logger.
1186 1186
 		global $wl_logger;
1187
-		$wl_logger = Wordlift_Log_Service::get_logger( 'WordLift' );
1187
+		$wl_logger = Wordlift_Log_Service::get_logger('WordLift');
1188 1188
 
1189 1189
 		// Load the `wl-api` end-point.
1190 1190
 		new Wordlift_Http_Api();
1191 1191
 
1192 1192
 		// Load the Install Service.
1193
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'install/class-wordlift-install-service.php';
1193
+		require_once plugin_dir_path(dirname(__FILE__)).'install/class-wordlift-install-service.php';
1194 1194
 		$this->install_service = new Wordlift_Install_Service();
1195 1195
 
1196 1196
 		/** Services. */
1197 1197
 		// Create the configuration service.
1198 1198
 		$this->configuration_service = new Wordlift_Configuration_Service();
1199
-		$api_service                 = new Wordlift_Api_Service( $this->configuration_service );
1199
+		$api_service                 = new Wordlift_Api_Service($this->configuration_service);
1200 1200
 
1201 1201
 		// Create an entity type service instance. It'll be later bound to the init action.
1202
-		$this->entity_post_type_service = new Wordlift_Entity_Post_Type_Service( Wordlift_Entity_Service::TYPE_NAME, $this->configuration_service->get_entity_base_path() );
1202
+		$this->entity_post_type_service = new Wordlift_Entity_Post_Type_Service(Wordlift_Entity_Service::TYPE_NAME, $this->configuration_service->get_entity_base_path());
1203 1203
 
1204 1204
 		// Create an entity link service instance. It'll be later bound to the post_type_link and pre_get_posts actions.
1205
-		$this->entity_link_service = new Wordlift_Entity_Link_Service( $this->entity_post_type_service, $this->configuration_service->get_entity_base_path() );
1205
+		$this->entity_link_service = new Wordlift_Entity_Link_Service($this->entity_post_type_service, $this->configuration_service->get_entity_base_path());
1206 1206
 
1207 1207
 		// Create an instance of the UI service.
1208 1208
 		$this->ui_service = new Wordlift_UI_Service();
@@ -1211,30 +1211,30 @@  discard block
 block discarded – undo
1211 1211
 		$this->thumbnail_service = new Wordlift_Thumbnail_Service();
1212 1212
 
1213 1213
 		$this->sparql_service        = new Wordlift_Sparql_Service();
1214
-		$schema_url_property_service = new Wordlift_Schema_Url_Property_Service( $this->sparql_service );
1214
+		$schema_url_property_service = new Wordlift_Schema_Url_Property_Service($this->sparql_service);
1215 1215
 		$this->notice_service        = new Wordlift_Notice_Service();
1216 1216
 		$this->relation_service      = new Wordlift_Relation_Service();
1217 1217
 
1218
-		$entity_uri_cache_service = new Wordlift_File_Cache_Service( WL_TEMP_DIR . 'entity_uri/' );
1219
-		$this->entity_uri_service = new Wordlift_Cached_Entity_Uri_Service( $this->configuration_service, $entity_uri_cache_service );
1220
-		$this->entity_service     = new Wordlift_Entity_Service( $this->ui_service, $this->relation_service, $this->entity_uri_service );
1221
-		$this->user_service       = new Wordlift_User_Service( $this->sparql_service, $this->entity_service );
1218
+		$entity_uri_cache_service = new Wordlift_File_Cache_Service(WL_TEMP_DIR.'entity_uri/');
1219
+		$this->entity_uri_service = new Wordlift_Cached_Entity_Uri_Service($this->configuration_service, $entity_uri_cache_service);
1220
+		$this->entity_service     = new Wordlift_Entity_Service($this->ui_service, $this->relation_service, $this->entity_uri_service);
1221
+		$this->user_service       = new Wordlift_User_Service($this->sparql_service, $this->entity_service);
1222 1222
 
1223 1223
 		// Instantiate the JSON-LD service.
1224
-		$property_getter = Wordlift_Property_Getter_Factory::create( $this->entity_service );
1224
+		$property_getter = Wordlift_Property_Getter_Factory::create($this->entity_service);
1225 1225
 
1226 1226
 		/** Linked Data. */
1227
-		$this->storage_factory   = new Wordlift_Storage_Factory( $this->entity_service, $this->user_service, $property_getter );
1228
-		$this->rendition_factory = new Wordlift_Sparql_Tuple_Rendition_Factory( $this->entity_service );
1227
+		$this->storage_factory   = new Wordlift_Storage_Factory($this->entity_service, $this->user_service, $property_getter);
1228
+		$this->rendition_factory = new Wordlift_Sparql_Tuple_Rendition_Factory($this->entity_service);
1229 1229
 
1230
-		$this->schema_service = new Wordlift_Schema_Service( $this->storage_factory, $this->rendition_factory, $this->configuration_service );
1230
+		$this->schema_service = new Wordlift_Schema_Service($this->storage_factory, $this->rendition_factory, $this->configuration_service);
1231 1231
 
1232 1232
 		// Create a new instance of the Redirect service.
1233
-		$this->redirect_service    = new Wordlift_Redirect_Service( $this->entity_uri_service );
1234
-		$this->entity_type_service = new Wordlift_Entity_Type_Service( $this->schema_service );
1233
+		$this->redirect_service    = new Wordlift_Redirect_Service($this->entity_uri_service);
1234
+		$this->entity_type_service = new Wordlift_Entity_Type_Service($this->schema_service);
1235 1235
 
1236 1236
 		// Create a new instance of the Timeline service and Timeline shortcode.
1237
-		$this->timeline_service = new Wordlift_Timeline_Service( $this->entity_service, $this->entity_type_service );
1237
+		$this->timeline_service = new Wordlift_Timeline_Service($this->entity_service, $this->entity_type_service);
1238 1238
 
1239 1239
 		$this->entity_types_taxonomy_walker = new Wordlift_Entity_Types_Taxonomy_Walker();
1240 1240
 
@@ -1248,36 +1248,36 @@  discard block
 block discarded – undo
1248 1248
 		$this->primashop_adapter = new Wordlift_PrimaShop_Adapter();
1249 1249
 
1250 1250
 		// Create an import service instance to hook later to WP's import function.
1251
-		$this->import_service = new Wordlift_Import_Service( $this->entity_post_type_service, $this->entity_service, $this->schema_service, $this->sparql_service, $this->configuration_service->get_dataset_uri() );
1251
+		$this->import_service = new Wordlift_Import_Service($this->entity_post_type_service, $this->entity_service, $this->schema_service, $this->sparql_service, $this->configuration_service->get_dataset_uri());
1252 1252
 
1253
-		$uri_service = new Wordlift_Uri_Service( $GLOBALS['wpdb'] );
1253
+		$uri_service = new Wordlift_Uri_Service($GLOBALS['wpdb']);
1254 1254
 
1255 1255
 		// Create the entity rating service.
1256
-		$this->rating_service = new Wordlift_Rating_Service( $this->entity_service, $this->entity_type_service, $this->notice_service );
1256
+		$this->rating_service = new Wordlift_Rating_Service($this->entity_service, $this->entity_type_service, $this->notice_service);
1257 1257
 
1258 1258
 		// Create entity list customization (wp-admin/edit.php).
1259
-		$this->entity_list_service = new Wordlift_Entity_List_Service( $this->rating_service );
1259
+		$this->entity_list_service = new Wordlift_Entity_List_Service($this->rating_service);
1260 1260
 
1261 1261
 		// Create a new instance of the Redirect service.
1262
-		$this->dashboard_service = new Wordlift_Dashboard_Service( $this->rating_service, $this->entity_service );
1262
+		$this->dashboard_service = new Wordlift_Dashboard_Service($this->rating_service, $this->entity_service);
1263 1263
 
1264 1264
 		// Create an instance of the Publisher Service and the AJAX Adapter.
1265
-		$this->publisher_service = new Wordlift_Publisher_Service( $this->configuration_service );
1266
-		$this->property_factory  = new Wordlift_Property_Factory( $schema_url_property_service );
1267
-		$this->property_factory->register( Wordlift_Schema_Url_Property_Service::META_KEY, $schema_url_property_service );
1265
+		$this->publisher_service = new Wordlift_Publisher_Service($this->configuration_service);
1266
+		$this->property_factory  = new Wordlift_Property_Factory($schema_url_property_service);
1267
+		$this->property_factory->register(Wordlift_Schema_Url_Property_Service::META_KEY, $schema_url_property_service);
1268 1268
 
1269 1269
 		$attachment_service = new Wordlift_Attachment_Service();
1270 1270
 
1271 1271
 		// Instantiate the JSON-LD service.
1272
-		$property_getter                       = Wordlift_Property_Getter_Factory::create( $this->entity_service );
1273
-		$this->post_to_jsonld_converter        = new Wordlift_Post_To_Jsonld_Converter( $this->entity_type_service, $this->entity_service, $this->user_service, $attachment_service, $this->configuration_service );
1274
-		$this->entity_post_to_jsonld_converter = new Wordlift_Entity_Post_To_Jsonld_Converter( $this->entity_type_service, $this->entity_service, $this->user_service, $attachment_service, $property_getter, $schemaorg_property_service, $this->post_to_jsonld_converter );
1275
-		$this->postid_to_jsonld_converter      = new Wordlift_Postid_To_Jsonld_Converter( $this->entity_service, $this->entity_post_to_jsonld_converter, $this->post_to_jsonld_converter );
1276
-		$this->jsonld_website_converter        = new Wordlift_Website_Jsonld_Converter( $this->entity_type_service, $this->entity_service, $this->user_service, $attachment_service, $this->configuration_service );
1272
+		$property_getter                       = Wordlift_Property_Getter_Factory::create($this->entity_service);
1273
+		$this->post_to_jsonld_converter        = new Wordlift_Post_To_Jsonld_Converter($this->entity_type_service, $this->entity_service, $this->user_service, $attachment_service, $this->configuration_service);
1274
+		$this->entity_post_to_jsonld_converter = new Wordlift_Entity_Post_To_Jsonld_Converter($this->entity_type_service, $this->entity_service, $this->user_service, $attachment_service, $property_getter, $schemaorg_property_service, $this->post_to_jsonld_converter);
1275
+		$this->postid_to_jsonld_converter      = new Wordlift_Postid_To_Jsonld_Converter($this->entity_service, $this->entity_post_to_jsonld_converter, $this->post_to_jsonld_converter);
1276
+		$this->jsonld_website_converter        = new Wordlift_Website_Jsonld_Converter($this->entity_type_service, $this->entity_service, $this->user_service, $attachment_service, $this->configuration_service);
1277 1277
 
1278
-		$jsonld_cache                            = new Ttl_Cache( 'jsonld', 86400 );
1279
-		$this->cached_postid_to_jsonld_converter = new Wordlift_Cached_Post_Converter( $this->postid_to_jsonld_converter, $this->configuration_service, $jsonld_cache );
1280
-		$this->jsonld_service                    = new Wordlift_Jsonld_Service( $this->entity_service, $this->cached_postid_to_jsonld_converter, $this->jsonld_website_converter );
1278
+		$jsonld_cache                            = new Ttl_Cache('jsonld', 86400);
1279
+		$this->cached_postid_to_jsonld_converter = new Wordlift_Cached_Post_Converter($this->postid_to_jsonld_converter, $this->configuration_service, $jsonld_cache);
1280
+		$this->jsonld_service                    = new Wordlift_Jsonld_Service($this->entity_service, $this->cached_postid_to_jsonld_converter, $this->jsonld_website_converter);
1281 1281
 
1282 1282
 		/*
1283 1283
 		 * Load the `Wordlift_Term_JsonLd_Adapter`.
@@ -1286,29 +1286,29 @@  discard block
 block discarded – undo
1286 1286
 		 *
1287 1287
 		 * @since 3.20.0
1288 1288
 		 */
1289
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wordlift-term-jsonld-adapter.php';
1290
-		$term_jsonld_adapter = new Wordlift_Term_JsonLd_Adapter( $this->entity_uri_service, $this->jsonld_service );
1289
+		require_once plugin_dir_path(dirname(__FILE__)).'public/class-wordlift-term-jsonld-adapter.php';
1290
+		$term_jsonld_adapter = new Wordlift_Term_JsonLd_Adapter($this->entity_uri_service, $this->jsonld_service);
1291 1291
 		$jsonld_service      = new Jsonld_Service(
1292 1292
 			$this->jsonld_service,
1293 1293
 			$term_jsonld_adapter,
1294
-			new Jsonld_User_Service( $this->user_service ) );
1295
-		new Jsonld_Endpoint( $jsonld_service, $this->entity_uri_service );
1294
+			new Jsonld_User_Service($this->user_service) );
1295
+		new Jsonld_Endpoint($jsonld_service, $this->entity_uri_service);
1296 1296
 
1297 1297
 		// Prints the JSON-LD in the head.
1298
-		new Jsonld_Adapter( $this->jsonld_service );
1298
+		new Jsonld_Adapter($this->jsonld_service);
1299 1299
 
1300
-		new Jsonld_By_Id_Endpoint( $this->jsonld_service, $this->entity_uri_service );
1300
+		new Jsonld_By_Id_Endpoint($this->jsonld_service, $this->entity_uri_service);
1301 1301
 
1302
-		$this->key_validation_service = new Wordlift_Key_Validation_Service( $this->configuration_service );
1303
-		$this->content_filter_service = new Wordlift_Content_Filter_Service( $this->entity_service, $this->configuration_service, $this->entity_uri_service );
1302
+		$this->key_validation_service = new Wordlift_Key_Validation_Service($this->configuration_service);
1303
+		$this->content_filter_service = new Wordlift_Content_Filter_Service($this->entity_service, $this->configuration_service, $this->entity_uri_service);
1304 1304
 		// Creating Faq Content filter service.
1305 1305
 		$this->faq_content_filter_service = new Faq_Content_Filter();
1306
-		$this->relation_rebuild_service   = new Wordlift_Relation_Rebuild_Service( $this->content_filter_service, $this->entity_service );
1307
-		$this->sample_data_service        = new Wordlift_Sample_Data_Service( $this->entity_type_service, $this->configuration_service, $this->user_service );
1308
-		$this->sample_data_ajax_adapter   = new Wordlift_Sample_Data_Ajax_Adapter( $this->sample_data_service );
1309
-		$this->reference_rebuild_service  = new Wordlift_Reference_Rebuild_Service( $this->entity_service );
1306
+		$this->relation_rebuild_service   = new Wordlift_Relation_Rebuild_Service($this->content_filter_service, $this->entity_service);
1307
+		$this->sample_data_service        = new Wordlift_Sample_Data_Service($this->entity_type_service, $this->configuration_service, $this->user_service);
1308
+		$this->sample_data_ajax_adapter   = new Wordlift_Sample_Data_Ajax_Adapter($this->sample_data_service);
1309
+		$this->reference_rebuild_service  = new Wordlift_Reference_Rebuild_Service($this->entity_service);
1310 1310
 
1311
-		$this->loader->add_action( 'enqueue_block_editor_assets', $this, 'add_wl_enabled_blocks' );
1311
+		$this->loader->add_action('enqueue_block_editor_assets', $this, 'add_wl_enabled_blocks');
1312 1312
 
1313 1313
 		/**
1314 1314
 		 * Filter: wl_feature__enable__blocks.
@@ -1318,15 +1318,15 @@  discard block
 block discarded – undo
1318 1318
 		 * @return bool
1319 1319
 		 * @since 3.27.6
1320 1320
 		 */
1321
-		if ( apply_filters( 'wl_feature__enable__blocks', true ) ) {
1321
+		if (apply_filters('wl_feature__enable__blocks', true)) {
1322 1322
 			// Initialize the short-codes.
1323
-			new Async_Template_Decorator( new Wordlift_Navigator_Shortcode() );
1323
+			new Async_Template_Decorator(new Wordlift_Navigator_Shortcode());
1324 1324
 			new Wordlift_Chord_Shortcode();
1325 1325
 			new Wordlift_Geomap_Shortcode();
1326 1326
 			new Wordlift_Timeline_Shortcode();
1327
-			new Wordlift_Related_Entities_Cloud_Shortcode( $this->relation_service );
1328
-			new Wordlift_Vocabulary_Shortcode( $this->configuration_service );
1329
-			new Async_Template_Decorator( new Wordlift_Faceted_Search_Shortcode() );
1327
+			new Wordlift_Related_Entities_Cloud_Shortcode($this->relation_service);
1328
+			new Wordlift_Vocabulary_Shortcode($this->configuration_service);
1329
+			new Async_Template_Decorator(new Wordlift_Faceted_Search_Shortcode());
1330 1330
 		}
1331 1331
 
1332 1332
 		new Wordlift_Products_Navigator_Shortcode();
@@ -1339,18 +1339,18 @@  discard block
 block discarded – undo
1339 1339
 		new Wordlift_Seo_Service();
1340 1340
 
1341 1341
 		// Initialize the AMP service.
1342
-		new Wordlift_AMP_Service( $this->jsonld_service );
1342
+		new Wordlift_AMP_Service($this->jsonld_service);
1343 1343
 
1344 1344
 		/** Services. */
1345 1345
 		$this->google_analytics_export_service = new Wordlift_Google_Analytics_Export_Service();
1346 1346
 		new Wordlift_Image_Service();
1347 1347
 
1348 1348
 		/** Adapters. */
1349
-		$this->entity_type_adapter    = new Wordlift_Entity_Type_Adapter( $this->entity_type_service );
1350
-		$this->publisher_ajax_adapter = new Wordlift_Publisher_Ajax_Adapter( $this->publisher_service );
1351
-		$this->tinymce_adapter        = new Wordlift_Tinymce_Adapter( $this );
1349
+		$this->entity_type_adapter    = new Wordlift_Entity_Type_Adapter($this->entity_type_service);
1350
+		$this->publisher_ajax_adapter = new Wordlift_Publisher_Ajax_Adapter($this->publisher_service);
1351
+		$this->tinymce_adapter        = new Wordlift_Tinymce_Adapter($this);
1352 1352
 		//$this->faq_tinymce_adapter      = new Faq_Tinymce_Adapter();
1353
-		$this->relation_rebuild_adapter = new Wordlift_Relation_Rebuild_Adapter( $this->relation_rebuild_service );
1353
+		$this->relation_rebuild_adapter = new Wordlift_Relation_Rebuild_Adapter($this->relation_rebuild_service);
1354 1354
 
1355 1355
 		/*
1356 1356
 		 * Exclude our public js from WP-Rocket.
@@ -1368,9 +1368,9 @@  discard block
 block discarded – undo
1368 1368
 		);
1369 1369
 
1370 1370
 		$that = $this;
1371
-		add_action( 'plugins_loaded', function () use ( $that ) {
1372
-			if ( ! apply_filters( 'wl_feature__enable__dataset-ng', false ) ) {
1373
-				new Wordlift_Linked_Data_Service( $that->entity_service, $that->entity_type_service, $that->schema_service, $that->sparql_service );
1371
+		add_action('plugins_loaded', function() use ($that) {
1372
+			if ( ! apply_filters('wl_feature__enable__dataset-ng', false)) {
1373
+				new Wordlift_Linked_Data_Service($that->entity_service, $that->entity_type_service, $that->schema_service, $that->sparql_service);
1374 1374
 				new Wordlift_Sparql_Query_Async_Task();
1375 1375
 				new Wordlift_Push_References_Async_Task();
1376 1376
 			}
@@ -1385,14 +1385,14 @@  discard block
 block discarded – undo
1385 1385
 		$this->language_select_element = new Wordlift_Admin_Language_Select_Element();
1386 1386
 		$this->country_select_element  = new Wordlift_Admin_Country_Select_Element();
1387 1387
 		$tabs_element                  = new Wordlift_Admin_Tabs_Element();
1388
-		$this->publisher_element       = new Wordlift_Admin_Publisher_Element( $this->configuration_service, $this->publisher_service, $tabs_element, $this->select2_element );
1389
-		$this->author_element          = new Wordlift_Admin_Author_Element( $this->publisher_service, $this->select2_element );
1388
+		$this->publisher_element       = new Wordlift_Admin_Publisher_Element($this->configuration_service, $this->publisher_service, $tabs_element, $this->select2_element);
1389
+		$this->author_element          = new Wordlift_Admin_Author_Element($this->publisher_service, $this->select2_element);
1390 1390
 
1391
-		$this->settings_page             = new Wordlift_Admin_Settings_Page( $this->configuration_service, $this->entity_service, $this->input_element, $this->language_select_element, $this->country_select_element, $this->publisher_element, $this->radio_input_element );
1392
-		$this->settings_page_action_link = new Wordlift_Admin_Settings_Page_Action_Link( $this->settings_page );
1391
+		$this->settings_page             = new Wordlift_Admin_Settings_Page($this->configuration_service, $this->entity_service, $this->input_element, $this->language_select_element, $this->country_select_element, $this->publisher_element, $this->radio_input_element);
1392
+		$this->settings_page_action_link = new Wordlift_Admin_Settings_Page_Action_Link($this->settings_page);
1393 1393
 
1394
-		$this->analytics_settings_page             = new Wordlift_Admin_Settings_Analytics_Page( $this->configuration_service, $this->input_element, $this->radio_input_element );
1395
-		$this->analytics_settings_page_action_link = new Wordlift_Admin_Settings_Analytics_Page_Action_Link( $this->analytics_settings_page );
1394
+		$this->analytics_settings_page             = new Wordlift_Admin_Settings_Analytics_Page($this->configuration_service, $this->input_element, $this->radio_input_element);
1395
+		$this->analytics_settings_page_action_link = new Wordlift_Admin_Settings_Analytics_Page_Action_Link($this->analytics_settings_page);
1396 1396
 		$this->analytics_connect                   = new Wordlift_Analytics_Connect();
1397 1397
 
1398 1398
 		// Pages.
@@ -1403,9 +1403,9 @@  discard block
 block discarded – undo
1403 1403
 		 *
1404 1404
 		 * @see https://github.com/insideout10/wordlift-plugin/issues/914
1405 1405
 		 */
1406
-		if ( apply_filters( 'wl_can_see_classification_box', true ) ) {
1407
-			require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wordlift-admin-post-edit-page.php';
1408
-			new Wordlift_Admin_Post_Edit_Page( $this );
1406
+		if (apply_filters('wl_can_see_classification_box', true)) {
1407
+			require_once plugin_dir_path(dirname(__FILE__)).'admin/class-wordlift-admin-post-edit-page.php';
1408
+			new Wordlift_Admin_Post_Edit_Page($this);
1409 1409
 		}
1410 1410
 		new Wordlift_Entity_Type_Admin_Service();
1411 1411
 
@@ -1419,23 +1419,23 @@  discard block
 block discarded – undo
1419 1419
 		$this->related_entities_cloud_widget = new Wordlift_Related_Entities_Cloud_Widget();
1420 1420
 
1421 1421
 		/* WordPress Admin. */
1422
-		$this->download_your_data_page = new Wordlift_Admin_Download_Your_Data_Page( $this->configuration_service );
1423
-		$this->status_page             = new Wordlift_Admin_Status_Page( $this->entity_service, $this->sparql_service );
1422
+		$this->download_your_data_page = new Wordlift_Admin_Download_Your_Data_Page($this->configuration_service);
1423
+		$this->status_page             = new Wordlift_Admin_Status_Page($this->entity_service, $this->sparql_service);
1424 1424
 
1425 1425
 		// Create an instance of the install wizard.
1426
-		$this->admin_setup = new Wordlift_Admin_Setup( $this->configuration_service, $this->key_validation_service, $this->entity_service, $this->language_select_element, $this->country_select_element );
1426
+		$this->admin_setup = new Wordlift_Admin_Setup($this->configuration_service, $this->key_validation_service, $this->entity_service, $this->language_select_element, $this->country_select_element);
1427 1427
 
1428
-		$this->category_taxonomy_service = new Wordlift_Category_Taxonomy_Service( $this->entity_post_type_service );
1428
+		$this->category_taxonomy_service = new Wordlift_Category_Taxonomy_Service($this->entity_post_type_service);
1429 1429
 
1430 1430
 		// User Profile.
1431
-		new Wordlift_Admin_User_Profile_Page( $this->author_element, $this->user_service );
1431
+		new Wordlift_Admin_User_Profile_Page($this->author_element, $this->user_service);
1432 1432
 
1433 1433
 		$this->entity_page_service = new Wordlift_Entity_Page_Service();
1434 1434
 
1435 1435
 		// Load the debug service if WP is in debug mode.
1436
-		if ( defined( 'WP_DEBUG' ) && WP_DEBUG ) {
1437
-			require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-debug-service.php';
1438
-			new Wordlift_Debug_Service( $this->entity_service, $uri_service );
1436
+		if (defined('WP_DEBUG') && WP_DEBUG) {
1437
+			require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-debug-service.php';
1438
+			new Wordlift_Debug_Service($this->entity_service, $uri_service);
1439 1439
 		}
1440 1440
 
1441 1441
 		// Remote Image Service.
@@ -1448,12 +1448,12 @@  discard block
 block discarded – undo
1448 1448
 		 *
1449 1449
 		 * @see https://github.com/insideout10/wordlift-plugin/issues/852.
1450 1450
 		 */
1451
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wordlift-batch-action.php';
1452
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/mapping/class-wordlift-mapping-service.php';
1453
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/mapping/class-wordlift-mapping-ajax-adapter.php';
1451
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-wordlift-batch-action.php';
1452
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/mapping/class-wordlift-mapping-service.php';
1453
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/mapping/class-wordlift-mapping-ajax-adapter.php';
1454 1454
 
1455 1455
 		// Create an instance of the Mapping Service and assign it to the Ajax Adapter.
1456
-		new Wordlift_Mapping_Ajax_Adapter( new Wordlift_Mapping_Service( Wordlift_Entity_Type_Service::get_instance() ) );
1456
+		new Wordlift_Mapping_Ajax_Adapter(new Wordlift_Mapping_Service(Wordlift_Entity_Type_Service::get_instance()));
1457 1457
 
1458 1458
 		/*
1459 1459
 		 * Batch Operations. They're similar to Batch Actions but do not require working on post types.
@@ -1462,8 +1462,8 @@  discard block
 block discarded – undo
1462 1462
 		 *
1463 1463
 		 * @since 3.20.0
1464 1464
 		 */
1465
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/batch/intf-wordlift-batch-operation.php';
1466
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/batch/class-wordlift-batch-operation-ajax-adapter.php';
1465
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/batch/intf-wordlift-batch-operation.php';
1466
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/batch/class-wordlift-batch-operation-ajax-adapter.php';
1467 1467
 
1468 1468
 		/*
1469 1469
 		 * Add the Search Keywords taxonomy to manage the Search Keywords on WLS.
@@ -1472,8 +1472,8 @@  discard block
 block discarded – undo
1472 1472
 		 *
1473 1473
 		 * @since 3.20.0
1474 1474
 		 */
1475
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/search-keywords/class-wordlift-search-keyword-taxonomy.php';
1476
-		new Wordlift_Search_Keyword_Taxonomy( $api_service );
1475
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/search-keywords/class-wordlift-search-keyword-taxonomy.php';
1476
+		new Wordlift_Search_Keyword_Taxonomy($api_service);
1477 1477
 
1478 1478
 		/*
1479 1479
 		 * Load the Mappings JSON-LD post processing.
@@ -1486,11 +1486,11 @@  discard block
 block discarded – undo
1486 1486
 		new Post_Type_Rule_Validator();
1487 1487
 		// Taxonomy term rule validator for validating rules for term pages.
1488 1488
 		new Taxonomy_Term_Rule_Validator();
1489
-		$rule_validators_registry = new Rule_Validators_Registry( $default_rule_validator );
1490
-		$rule_groups_validator    = new Rule_Groups_Validator( $rule_validators_registry );
1491
-		$mappings_validator       = new Mappings_Validator( $mappings_dbo, $rule_groups_validator );
1489
+		$rule_validators_registry = new Rule_Validators_Registry($default_rule_validator);
1490
+		$rule_groups_validator    = new Rule_Groups_Validator($rule_validators_registry);
1491
+		$mappings_validator       = new Mappings_Validator($mappings_dbo, $rule_groups_validator);
1492 1492
 
1493
-		new Url_To_Entity_Transform_Function( $this->entity_uri_service );
1493
+		new Url_To_Entity_Transform_Function($this->entity_uri_service);
1494 1494
 		new Taxonomy_To_Terms_Transform_Function();
1495 1495
 		new Post_Id_To_Entity_Transform_Function();
1496 1496
 		$mappings_transform_functions_registry = new Mappings_Transform_Functions_Registry();
@@ -1500,7 +1500,7 @@  discard block
 block discarded – undo
1500 1500
 		 * Intiailize the acf group data formatter.
1501 1501
 		 */
1502 1502
 		new Acf_Group_Formatter();
1503
-		new Jsonld_Converter( $mappings_validator, $mappings_transform_functions_registry );
1503
+		new Jsonld_Converter($mappings_validator, $mappings_transform_functions_registry);
1504 1504
 
1505 1505
 		/**
1506 1506
 		 * @since 3.26.0
@@ -1521,7 +1521,7 @@  discard block
 block discarded – undo
1521 1521
 		/*
1522 1522
 		 * Create a singleton for the Analysis_Response_Ops_Factory.
1523 1523
 		 */
1524
-		$entity_helper = new Entity_Helper( $this->entity_uri_service, $this->entity_service );
1524
+		$entity_helper = new Entity_Helper($this->entity_uri_service, $this->entity_service);
1525 1525
 		new Analysis_Response_Ops_Factory(
1526 1526
 			$this->entity_uri_service,
1527 1527
 			$this->entity_service,
@@ -1531,11 +1531,11 @@  discard block
 block discarded – undo
1531 1531
 		);
1532 1532
 
1533 1533
 		/** WL Autocomplete. */
1534
-		$autocomplete_service       = new All_Autocomplete_Service( array(
1534
+		$autocomplete_service = new All_Autocomplete_Service(array(
1535 1535
 			new Local_Autocomplete_Service(),
1536
-			new Linked_Data_Autocomplete_Service( $this->configuration_service, $entity_helper, $this->entity_uri_service, $this->entity_service ),
1537
-		) );
1538
-		$this->autocomplete_adapter = new Wordlift_Autocomplete_Adapter( $autocomplete_service );
1536
+			new Linked_Data_Autocomplete_Service($this->configuration_service, $entity_helper, $this->entity_uri_service, $this->entity_service),
1537
+		));
1538
+		$this->autocomplete_adapter = new Wordlift_Autocomplete_Adapter($autocomplete_service);
1539 1539
 
1540 1540
 		/**
1541 1541
 		 * @since 3.27.2
@@ -1544,10 +1544,10 @@  discard block
 block discarded – undo
1544 1544
 		 */
1545 1545
 		new Recipe_Maker_Post_Type_Hook();
1546 1546
 		$recipe_maker_validation_service = new Recipe_Maker_Validation_Service();
1547
-		new Recipe_Maker_Jsonld_Hook( $attachment_service, $recipe_maker_validation_service );
1548
-		new Recipe_Maker_After_Get_Jsonld_Hook( $recipe_maker_validation_service );
1549
-		new Recipe_Maker_Warning( $recipe_maker_validation_service );
1550
-		new Yoast_Jsonld( $recipe_maker_validation_service );
1547
+		new Recipe_Maker_Jsonld_Hook($attachment_service, $recipe_maker_validation_service);
1548
+		new Recipe_Maker_After_Get_Jsonld_Hook($recipe_maker_validation_service);
1549
+		new Recipe_Maker_Warning($recipe_maker_validation_service);
1550
+		new Yoast_Jsonld($recipe_maker_validation_service);
1551 1551
 
1552 1552
 		/**
1553 1553
 		 * @since 3.27.4
@@ -1568,9 +1568,9 @@  discard block
 block discarded – undo
1568 1568
 	private function set_locale() {
1569 1569
 
1570 1570
 		$plugin_i18n = new Wordlift_i18n();
1571
-		$plugin_i18n->set_domain( $this->get_plugin_name() );
1571
+		$plugin_i18n->set_domain($this->get_plugin_name());
1572 1572
 
1573
-		$this->loader->add_action( 'plugins_loaded', $plugin_i18n, 'load_plugin_textdomain' );
1573
+		$this->loader->add_action('plugins_loaded', $plugin_i18n, 'load_plugin_textdomain');
1574 1574
 
1575 1575
 	}
1576 1576
 
@@ -1591,29 +1591,29 @@  discard block
 block discarded – undo
1591 1591
 			$this->user_service
1592 1592
 		);
1593 1593
 
1594
-		$this->loader->add_action( 'admin_enqueue_scripts', $plugin_admin, 'enqueue_styles' );
1595
-		$this->loader->add_action( 'admin_enqueue_scripts', $plugin_admin, 'enqueue_scripts', 11 );
1594
+		$this->loader->add_action('admin_enqueue_scripts', $plugin_admin, 'enqueue_styles');
1595
+		$this->loader->add_action('admin_enqueue_scripts', $plugin_admin, 'enqueue_scripts', 11);
1596 1596
 
1597 1597
 		// Hook the init action to taxonomy services.
1598
-		$this->loader->add_action( 'init', $this->topic_taxonomy_service, 'init', 0 );
1599
-		$this->loader->add_action( 'init', $this->entity_types_taxonomy_service, 'init', 0 );
1598
+		$this->loader->add_action('init', $this->topic_taxonomy_service, 'init', 0);
1599
+		$this->loader->add_action('init', $this->entity_types_taxonomy_service, 'init', 0);
1600 1600
 
1601 1601
 		// Hook the deleted_post_meta action to the Thumbnail service.
1602
-		$this->loader->add_action( 'deleted_post_meta', $this->thumbnail_service, 'deleted_post_meta', 10, 4 );
1602
+		$this->loader->add_action('deleted_post_meta', $this->thumbnail_service, 'deleted_post_meta', 10, 4);
1603 1603
 
1604 1604
 		// Hook the added_post_meta action to the Thumbnail service.
1605
-		$this->loader->add_action( 'added_post_meta', $this->thumbnail_service, 'added_or_updated_post_meta', 10, 4 );
1605
+		$this->loader->add_action('added_post_meta', $this->thumbnail_service, 'added_or_updated_post_meta', 10, 4);
1606 1606
 
1607 1607
 		// Hook the updated_post_meta action to the Thumbnail service.
1608
-		$this->loader->add_action( 'updated_post_meta', $this->thumbnail_service, 'added_or_updated_post_meta', 10, 4 );
1608
+		$this->loader->add_action('updated_post_meta', $this->thumbnail_service, 'added_or_updated_post_meta', 10, 4);
1609 1609
 
1610 1610
 		// Hook the AJAX wl_timeline action to the Timeline service.
1611
-		$this->loader->add_action( 'wp_ajax_wl_timeline', $this->timeline_service, 'ajax_timeline' );
1611
+		$this->loader->add_action('wp_ajax_wl_timeline', $this->timeline_service, 'ajax_timeline');
1612 1612
 
1613 1613
 		// Register custom allowed redirect hosts.
1614
-		$this->loader->add_filter( 'allowed_redirect_hosts', $this->redirect_service, 'allowed_redirect_hosts' );
1614
+		$this->loader->add_filter('allowed_redirect_hosts', $this->redirect_service, 'allowed_redirect_hosts');
1615 1615
 		// Hook the AJAX wordlift_redirect action to the Redirect service.
1616
-		$this->loader->add_action( 'wp_ajax_wordlift_redirect', $this->redirect_service, 'ajax_redirect' );
1616
+		$this->loader->add_action('wp_ajax_wordlift_redirect', $this->redirect_service, 'ajax_redirect');
1617 1617
 
1618 1618
 		/*
1619 1619
 		 * The old dashboard is replaced with dashboard v2.
@@ -1631,46 +1631,46 @@  discard block
 block discarded – undo
1631 1631
 
1632 1632
 		// Hook save_post to the entity service to update custom fields (such as alternate labels).
1633 1633
 		// We have a priority of 9 because we want to be executed before data is sent to Redlink.
1634
-		$this->loader->add_action( 'save_post', $this->entity_service, 'save_post', 9, 3 );
1635
-		$this->loader->add_action( 'save_post', $this->rating_service, 'set_rating_for', 20, 1 );
1634
+		$this->loader->add_action('save_post', $this->entity_service, 'save_post', 9, 3);
1635
+		$this->loader->add_action('save_post', $this->rating_service, 'set_rating_for', 20, 1);
1636 1636
 
1637
-		$this->loader->add_action( 'edit_form_before_permalink', $this->entity_service, 'edit_form_before_permalink', 10, 1 );
1638
-		$this->loader->add_action( 'in_admin_header', $this->rating_service, 'in_admin_header' );
1637
+		$this->loader->add_action('edit_form_before_permalink', $this->entity_service, 'edit_form_before_permalink', 10, 1);
1638
+		$this->loader->add_action('in_admin_header', $this->rating_service, 'in_admin_header');
1639 1639
 
1640 1640
 		// Entity listing customization (wp-admin/edit.php)
1641 1641
 		// Add custom columns.
1642
-		$this->loader->add_filter( 'manage_entity_posts_columns', $this->entity_list_service, 'register_custom_columns' );
1642
+		$this->loader->add_filter('manage_entity_posts_columns', $this->entity_list_service, 'register_custom_columns');
1643 1643
 		// no explicit entity as it prevents handling of other post types.
1644
-		$this->loader->add_filter( 'manage_posts_custom_column', $this->entity_list_service, 'render_custom_columns', 10, 2 );
1644
+		$this->loader->add_filter('manage_posts_custom_column', $this->entity_list_service, 'render_custom_columns', 10, 2);
1645 1645
 		// Add 4W selection.
1646
-		$this->loader->add_action( 'restrict_manage_posts', $this->entity_list_service, 'restrict_manage_posts_classification_scope' );
1647
-		$this->loader->add_filter( 'posts_clauses', $this->entity_list_service, 'posts_clauses_classification_scope' );
1648
-		$this->loader->add_action( 'pre_get_posts', $this->entity_list_service, 'pre_get_posts' );
1649
-		$this->loader->add_action( 'load-edit.php', $this->entity_list_service, 'load_edit' );
1646
+		$this->loader->add_action('restrict_manage_posts', $this->entity_list_service, 'restrict_manage_posts_classification_scope');
1647
+		$this->loader->add_filter('posts_clauses', $this->entity_list_service, 'posts_clauses_classification_scope');
1648
+		$this->loader->add_action('pre_get_posts', $this->entity_list_service, 'pre_get_posts');
1649
+		$this->loader->add_action('load-edit.php', $this->entity_list_service, 'load_edit');
1650 1650
 
1651 1651
 		/*
1652 1652
 		 * If `All Entity Types` is disable, use the radio button Walker.
1653 1653
 		 *
1654 1654
 		 * @see https://github.com/insideout10/wordlift-plugin/issues/835
1655 1655
 		 */
1656
-		if ( ! WL_ALL_ENTITY_TYPES ) {
1657
-			$this->loader->add_filter( 'wp_terms_checklist_args', $this->entity_types_taxonomy_walker, 'terms_checklist_args' );
1656
+		if ( ! WL_ALL_ENTITY_TYPES) {
1657
+			$this->loader->add_filter('wp_terms_checklist_args', $this->entity_types_taxonomy_walker, 'terms_checklist_args');
1658 1658
 		}
1659 1659
 
1660 1660
 		// Hook the PrimaShop adapter to <em>prima_metabox_entity_header_args</em> in order to add header support for
1661 1661
 		// entities.
1662
-		$this->loader->add_filter( 'prima_metabox_entity_header_args', $this->primashop_adapter, 'prima_metabox_entity_header_args', 10, 2 );
1662
+		$this->loader->add_filter('prima_metabox_entity_header_args', $this->primashop_adapter, 'prima_metabox_entity_header_args', 10, 2);
1663 1663
 
1664 1664
 		// Filter imported post meta.
1665
-		$this->loader->add_filter( 'wp_import_post_meta', $this->import_service, 'wp_import_post_meta', 10, 3 );
1665
+		$this->loader->add_filter('wp_import_post_meta', $this->import_service, 'wp_import_post_meta', 10, 3);
1666 1666
 
1667 1667
 		// Notify the import service when an import starts and ends.
1668
-		$this->loader->add_action( 'import_start', $this->import_service, 'import_start', 10, 0 );
1669
-		$this->loader->add_action( 'import_end', $this->import_service, 'import_end', 10, 0 );
1668
+		$this->loader->add_action('import_start', $this->import_service, 'import_start', 10, 0);
1669
+		$this->loader->add_action('import_end', $this->import_service, 'import_end', 10, 0);
1670 1670
 
1671 1671
 		// Hook the AJAX wl_rebuild action to the Rebuild Service.
1672
-		$this->loader->add_action( 'wp_ajax_wl_rebuild', $this->rebuild_service, 'rebuild' );
1673
-		$this->loader->add_action( 'wp_ajax_wl_rebuild_references', $this->reference_rebuild_service, 'rebuild' );
1672
+		$this->loader->add_action('wp_ajax_wl_rebuild', $this->rebuild_service, 'rebuild');
1673
+		$this->loader->add_action('wp_ajax_wl_rebuild_references', $this->reference_rebuild_service, 'rebuild');
1674 1674
 
1675 1675
 		/**
1676 1676
 		 * Filter: wl_feature__enable__screens.
@@ -1680,34 +1680,34 @@  discard block
 block discarded – undo
1680 1680
 		 * @return bool
1681 1681
 		 * @since 3.27.6
1682 1682
 		 */
1683
-		if ( apply_filters( 'wl_feature__enable__screens', true ) ) {
1683
+		if (apply_filters('wl_feature__enable__screens', true)) {
1684 1684
 			// Hook the menu to the Download Your Data page.
1685
-			$this->loader->add_action( 'admin_menu', $this->download_your_data_page, 'admin_menu', 100, 0 );
1686
-			$this->loader->add_action( 'admin_menu', $this->status_page, 'admin_menu', 100, 0 );
1687
-			$this->loader->add_action( 'admin_menu', $this->entity_type_settings_admin_page, 'admin_menu', 100, 0 );
1685
+			$this->loader->add_action('admin_menu', $this->download_your_data_page, 'admin_menu', 100, 0);
1686
+			$this->loader->add_action('admin_menu', $this->status_page, 'admin_menu', 100, 0);
1687
+			$this->loader->add_action('admin_menu', $this->entity_type_settings_admin_page, 'admin_menu', 100, 0);
1688 1688
 		}
1689 1689
 		// Hook the admin-ajax.php?action=wl_download_your_data&out=xyz links.
1690
-		$this->loader->add_action( 'wp_ajax_wl_download_your_data', $this->download_your_data_page, 'download_your_data', 10 );
1690
+		$this->loader->add_action('wp_ajax_wl_download_your_data', $this->download_your_data_page, 'download_your_data', 10);
1691 1691
 
1692 1692
 		// Hook the AJAX wl_jsonld action to the JSON-LD service.
1693
-		$this->loader->add_action( 'wp_ajax_wl_jsonld', $this->jsonld_service, 'get' );
1694
-		$this->loader->add_action( 'admin_post_wl_jsonld', $this->jsonld_service, 'get' );
1695
-		$this->loader->add_action( 'admin_post_nopriv_wl_jsonld', $this->jsonld_service, 'get' );
1693
+		$this->loader->add_action('wp_ajax_wl_jsonld', $this->jsonld_service, 'get');
1694
+		$this->loader->add_action('admin_post_wl_jsonld', $this->jsonld_service, 'get');
1695
+		$this->loader->add_action('admin_post_nopriv_wl_jsonld', $this->jsonld_service, 'get');
1696 1696
 
1697 1697
 		// Hook the AJAX wl_validate_key action to the Key Validation service.
1698
-		$this->loader->add_action( 'wp_ajax_wl_validate_key', $this->key_validation_service, 'validate_key' );
1698
+		$this->loader->add_action('wp_ajax_wl_validate_key', $this->key_validation_service, 'validate_key');
1699 1699
 
1700 1700
 		// Hook the AJAX wl_update_country_options action to the countries.
1701
-		$this->loader->add_action( 'wp_ajax_wl_update_country_options', $this->country_select_element, 'get_options_html' );
1701
+		$this->loader->add_action('wp_ajax_wl_update_country_options', $this->country_select_element, 'get_options_html');
1702 1702
 
1703 1703
 		// Hook the `admin_init` function to the Admin Setup.
1704
-		$this->loader->add_action( 'admin_init', $this->admin_setup, 'admin_init' );
1704
+		$this->loader->add_action('admin_init', $this->admin_setup, 'admin_init');
1705 1705
 
1706 1706
 		// Hook the admin_init to the settings page.
1707
-		$this->loader->add_action( 'admin_init', $this->settings_page, 'admin_init' );
1708
-		$this->loader->add_action( 'admin_init', $this->analytics_settings_page, 'admin_init' );
1707
+		$this->loader->add_action('admin_init', $this->settings_page, 'admin_init');
1708
+		$this->loader->add_action('admin_init', $this->analytics_settings_page, 'admin_init');
1709 1709
 
1710
-		$this->loader->add_filter( 'admin_post_thumbnail_html', $this->publisher_service, 'add_featured_image_instruction' );
1710
+		$this->loader->add_filter('admin_post_thumbnail_html', $this->publisher_service, 'add_featured_image_instruction');
1711 1711
 
1712 1712
 		// Hook the menu creation on the general wordlift menu creation.
1713 1713
 		/**
@@ -1718,8 +1718,8 @@  discard block
 block discarded – undo
1718 1718
 		 * @return bool
1719 1719
 		 * @since 3.27.6
1720 1720
 		 */
1721
-		if ( apply_filters( 'wl_feature__enable__screens', true ) ) {
1722
-			$this->loader->add_action( 'wl_admin_menu', $this->settings_page, 'admin_menu', 10, 2 );
1721
+		if (apply_filters('wl_feature__enable__screens', true)) {
1722
+			$this->loader->add_action('wl_admin_menu', $this->settings_page, 'admin_menu', 10, 2);
1723 1723
 		}
1724 1724
 		/*
1725 1725
 		 * Display the `Wordlift_Admin_Search_Rankings_Page` page.
@@ -1728,7 +1728,7 @@  discard block
 block discarded – undo
1728 1728
 		 *
1729 1729
 		 * @since 3.20.0
1730 1730
 		 */
1731
-		if ( in_array( $this->configuration_service->get_package_type(), array( 'editorial', 'business' ) ) ) {
1731
+		if (in_array($this->configuration_service->get_package_type(), array('editorial', 'business'))) {
1732 1732
 			/**
1733 1733
 			 * Filter: wl_feature__enable__screens.
1734 1734
 			 *
@@ -1737,18 +1737,18 @@  discard block
 block discarded – undo
1737 1737
 			 * @return bool
1738 1738
 			 * @since 3.27.6
1739 1739
 			 */
1740
-			if ( apply_filters( 'wl_feature__enable__screens', true ) ) {
1740
+			if (apply_filters('wl_feature__enable__screens', true)) {
1741 1741
 				$admin_search_rankings_page = new Wordlift_Admin_Search_Rankings_Page();
1742
-				$this->loader->add_action( 'wl_admin_menu', $admin_search_rankings_page, 'admin_menu' );
1742
+				$this->loader->add_action('wl_admin_menu', $admin_search_rankings_page, 'admin_menu');
1743 1743
 			}
1744 1744
 		}
1745 1745
 
1746 1746
 		// Hook key update.
1747
-		$this->loader->add_action( 'pre_update_option_wl_general_settings', $this->configuration_service, 'maybe_update_dataset_uri', 10, 2 );
1748
-		$this->loader->add_action( 'update_option_wl_general_settings', $this->configuration_service, 'update_key', 10, 2 );
1747
+		$this->loader->add_action('pre_update_option_wl_general_settings', $this->configuration_service, 'maybe_update_dataset_uri', 10, 2);
1748
+		$this->loader->add_action('update_option_wl_general_settings', $this->configuration_service, 'update_key', 10, 2);
1749 1749
 
1750 1750
 		// Add additional action links to the WordLift plugin in the plugins page.
1751
-		$this->loader->add_filter( 'plugin_action_links_wordlift/wordlift.php', $this->settings_page_action_link, 'action_links', 10, 1 );
1751
+		$this->loader->add_filter('plugin_action_links_wordlift/wordlift.php', $this->settings_page_action_link, 'action_links', 10, 1);
1752 1752
 
1753 1753
 		/*
1754 1754
 		 * Remove the Analytics Settings link from the plugin page.
@@ -1759,25 +1759,25 @@  discard block
 block discarded – undo
1759 1759
 		// $this->loader->add_filter( 'plugin_action_links_wordlift/wordlift.php', $this->analytics_settings_page_action_link, 'action_links', 10, 1 );
1760 1760
 
1761 1761
 		// Hook the AJAX `wl_publisher` action name.
1762
-		$this->loader->add_action( 'wp_ajax_wl_publisher', $this->publisher_ajax_adapter, 'publisher' );
1762
+		$this->loader->add_action('wp_ajax_wl_publisher', $this->publisher_ajax_adapter, 'publisher');
1763 1763
 
1764 1764
 		// Hook row actions for the entity type list admin.
1765
-		$this->loader->add_filter( 'wl_entity_type_row_actions', $this->entity_type_admin_page, 'wl_entity_type_row_actions', 10, 2 );
1765
+		$this->loader->add_filter('wl_entity_type_row_actions', $this->entity_type_admin_page, 'wl_entity_type_row_actions', 10, 2);
1766 1766
 
1767 1767
 		/** Ajax actions. */
1768
-		$this->loader->add_action( 'wp_ajax_wl_google_analytics_export', $this->google_analytics_export_service, 'export' );
1768
+		$this->loader->add_action('wp_ajax_wl_google_analytics_export', $this->google_analytics_export_service, 'export');
1769 1769
 
1770 1770
 		// Hook capabilities manipulation to allow access to entity type admin
1771 1771
 		// page  on WordPress versions before 4.7.
1772 1772
 		global $wp_version;
1773
-		if ( version_compare( $wp_version, '4.7', '<' ) ) {
1774
-			$this->loader->add_filter( 'map_meta_cap', $this->entity_type_admin_page, 'enable_admin_access_pre_47', 10, 4 );
1773
+		if (version_compare($wp_version, '4.7', '<')) {
1774
+			$this->loader->add_filter('map_meta_cap', $this->entity_type_admin_page, 'enable_admin_access_pre_47', 10, 4);
1775 1775
 		}
1776 1776
 
1777
-		$this->loader->add_action( 'wl_async_wl_run_sparql_query', $this->sparql_service, 'run_sparql_query', 10, 1 );
1777
+		$this->loader->add_action('wl_async_wl_run_sparql_query', $this->sparql_service, 'run_sparql_query', 10, 1);
1778 1778
 
1779 1779
 		/** Adapters. */
1780
-		$this->loader->add_filter( 'mce_external_plugins', $this->tinymce_adapter, 'mce_external_plugins', 10, 1 );
1780
+		$this->loader->add_filter('mce_external_plugins', $this->tinymce_adapter, 'mce_external_plugins', 10, 1);
1781 1781
 		/**
1782 1782
 		 * Disabling Faq temporarily.
1783 1783
 		 * Load the tinymce editor button on the tool bar.
@@ -1788,56 +1788,56 @@  discard block
 block discarded – undo
1788 1788
 		//$this->loader->add_filter( 'mce_external_plugins', $this->faq_tinymce_adapter, 'register_faq_tinymce_plugin', 10, 1 );
1789 1789
 
1790 1790
 
1791
-		$this->loader->add_action( 'wp_ajax_wl_relation_rebuild_process_all', $this->relation_rebuild_adapter, 'process_all' );
1792
-		$this->loader->add_action( 'wp_ajax_wl_sample_data_create', $this->sample_data_ajax_adapter, 'create' );
1793
-		$this->loader->add_action( 'wp_ajax_wl_sample_data_delete', $this->sample_data_ajax_adapter, 'delete' );
1791
+		$this->loader->add_action('wp_ajax_wl_relation_rebuild_process_all', $this->relation_rebuild_adapter, 'process_all');
1792
+		$this->loader->add_action('wp_ajax_wl_sample_data_create', $this->sample_data_ajax_adapter, 'create');
1793
+		$this->loader->add_action('wp_ajax_wl_sample_data_delete', $this->sample_data_ajax_adapter, 'delete');
1794 1794
 		/**
1795 1795
 		 * @since 3.26.0
1796 1796
 		 */
1797
-		if ( apply_filters( 'wl_feature__enable__post_excerpt', true ) ) {
1797
+		if (apply_filters('wl_feature__enable__post_excerpt', true)) {
1798 1798
 			$excerpt_adapter = new Post_Excerpt_Meta_Box_Adapter();
1799
-			$this->loader->add_action( 'do_meta_boxes', $excerpt_adapter, 'replace_post_excerpt_meta_box' );
1799
+			$this->loader->add_action('do_meta_boxes', $excerpt_adapter, 'replace_post_excerpt_meta_box');
1800 1800
 			// Adding Rest route for the post excerpt
1801 1801
 			Post_Excerpt_Rest_Controller::register_routes();
1802 1802
 		}
1803 1803
 
1804
-		$this->loader->add_action( 'update_user_metadata', $this->user_service, 'update_user_metadata', 10, 5 );
1805
-		$this->loader->add_action( 'delete_user_metadata', $this->user_service, 'delete_user_metadata', 10, 5 );
1804
+		$this->loader->add_action('update_user_metadata', $this->user_service, 'update_user_metadata', 10, 5);
1805
+		$this->loader->add_action('delete_user_metadata', $this->user_service, 'delete_user_metadata', 10, 5);
1806 1806
 
1807 1807
 		// Handle the autocomplete request.
1808
-		add_action( 'wp_ajax_wl_autocomplete', array(
1808
+		add_action('wp_ajax_wl_autocomplete', array(
1809 1809
 			$this->autocomplete_adapter,
1810 1810
 			'wl_autocomplete',
1811
-		) );
1812
-		add_action( 'wp_ajax_nopriv_wl_autocomplete', array(
1811
+		));
1812
+		add_action('wp_ajax_nopriv_wl_autocomplete', array(
1813 1813
 			$this->autocomplete_adapter,
1814 1814
 			'wl_autocomplete',
1815
-		) );
1815
+		));
1816 1816
 
1817 1817
 		// Hooks to restrict multisite super admin from manipulating entity types.
1818
-		if ( is_multisite() ) {
1819
-			$this->loader->add_filter( 'map_meta_cap', $this->entity_type_admin_page, 'restrict_super_admin', 10, 4 );
1818
+		if (is_multisite()) {
1819
+			$this->loader->add_filter('map_meta_cap', $this->entity_type_admin_page, 'restrict_super_admin', 10, 4);
1820 1820
 		}
1821 1821
 
1822
-		$deactivator_feedback = new Wordlift_Deactivator_Feedback( $this->configuration_service );
1822
+		$deactivator_feedback = new Wordlift_Deactivator_Feedback($this->configuration_service);
1823 1823
 
1824
-		add_action( 'admin_footer', array( $deactivator_feedback, 'render_feedback_popup' ) );
1825
-		add_action( 'admin_enqueue_scripts', array( $deactivator_feedback, 'enqueue_popup_scripts' ) );
1826
-		add_action( 'wp_ajax_wl_deactivation_feedback', array( $deactivator_feedback, 'wl_deactivation_feedback' ) );
1824
+		add_action('admin_footer', array($deactivator_feedback, 'render_feedback_popup'));
1825
+		add_action('admin_enqueue_scripts', array($deactivator_feedback, 'enqueue_popup_scripts'));
1826
+		add_action('wp_ajax_wl_deactivation_feedback', array($deactivator_feedback, 'wl_deactivation_feedback'));
1827 1827
 
1828 1828
 		/**
1829 1829
 		 * Always allow the `wordlift/classification` block.
1830 1830
 		 *
1831 1831
 		 * @since 3.23.0
1832 1832
 		 */
1833
-		add_filter( 'allowed_block_types', function ( $value ) {
1833
+		add_filter('allowed_block_types', function($value) {
1834 1834
 
1835
-			if ( true === $value ) {
1835
+			if (true === $value) {
1836 1836
 				return $value;
1837 1837
 			}
1838 1838
 
1839
-			return array_merge( (array) $value, array( 'wordlift/classification' ) );
1840
-		}, PHP_INT_MAX );
1839
+			return array_merge((array) $value, array('wordlift/classification'));
1840
+		}, PHP_INT_MAX);
1841 1841
 
1842 1842
 		/**
1843 1843
 		 * @since 3.27.7
@@ -1855,58 +1855,58 @@  discard block
 block discarded – undo
1855 1855
 	 */
1856 1856
 	private function define_public_hooks() {
1857 1857
 
1858
-		$plugin_public = new Wordlift_Public( $this->get_plugin_name(), $this->get_version() );
1858
+		$plugin_public = new Wordlift_Public($this->get_plugin_name(), $this->get_version());
1859 1859
 
1860 1860
 		// Register the entity post type.
1861
-		$this->loader->add_action( 'init', $this->entity_post_type_service, 'register' );
1861
+		$this->loader->add_action('init', $this->entity_post_type_service, 'register');
1862 1862
 
1863 1863
 		// Bind the link generation and handling hooks to the entity link service.
1864
-		$this->loader->add_filter( 'post_type_link', $this->entity_link_service, 'post_type_link', 10, 4 );
1865
-		$this->loader->add_action( 'pre_get_posts', $this->entity_link_service, 'pre_get_posts', PHP_INT_MAX, 1 );
1864
+		$this->loader->add_filter('post_type_link', $this->entity_link_service, 'post_type_link', 10, 4);
1865
+		$this->loader->add_action('pre_get_posts', $this->entity_link_service, 'pre_get_posts', PHP_INT_MAX, 1);
1866 1866
 		// $this->loader->add_filter( 'wp_unique_post_slug_is_bad_flat_slug', $this->entity_link_service, 'wp_unique_post_slug_is_bad_flat_slug', 10, 3 );
1867 1867
 		// $this->loader->add_filter( 'wp_unique_post_slug_is_bad_hierarchical_slug', $this->entity_link_service, 'wp_unique_post_slug_is_bad_hierarchical_slug', 10, 4 );
1868 1868
 
1869
-		$this->loader->add_action( 'wp_enqueue_scripts', $plugin_public, 'enqueue_styles' );
1870
-		$this->loader->add_action( 'wp_enqueue_scripts', $plugin_public, 'enqueue_scripts' );
1871
-		$this->loader->add_action( 'wp_enqueue_scripts', $this->context_cards_service, 'enqueue_scripts' );
1869
+		$this->loader->add_action('wp_enqueue_scripts', $plugin_public, 'enqueue_styles');
1870
+		$this->loader->add_action('wp_enqueue_scripts', $plugin_public, 'enqueue_scripts');
1871
+		$this->loader->add_action('wp_enqueue_scripts', $this->context_cards_service, 'enqueue_scripts');
1872 1872
 
1873 1873
 		// Registering Faq_Content_Filter service used for removing faq question and answer tags from the html.
1874
-		$this->loader->add_filter( 'the_content', $this->faq_content_filter_service, 'remove_all_faq_question_and_answer_tags' );
1874
+		$this->loader->add_filter('the_content', $this->faq_content_filter_service, 'remove_all_faq_question_and_answer_tags');
1875 1875
 		// Hook the content filter service to add entity links.
1876
-		if ( ! defined( 'WL_DISABLE_CONTENT_FILTER' ) || ! WL_DISABLE_CONTENT_FILTER ) {
1877
-			$this->loader->add_filter( 'the_content', $this->content_filter_service, 'the_content' );
1876
+		if ( ! defined('WL_DISABLE_CONTENT_FILTER') || ! WL_DISABLE_CONTENT_FILTER) {
1877
+			$this->loader->add_filter('the_content', $this->content_filter_service, 'the_content');
1878 1878
 		}
1879 1879
 
1880 1880
 		// Hook the AJAX wl_timeline action to the Timeline service.
1881
-		$this->loader->add_action( 'wp_ajax_nopriv_wl_timeline', $this->timeline_service, 'ajax_timeline' );
1881
+		$this->loader->add_action('wp_ajax_nopriv_wl_timeline', $this->timeline_service, 'ajax_timeline');
1882 1882
 
1883 1883
 		// Hook the ShareThis service.
1884
-		$this->loader->add_filter( 'the_content', $this->sharethis_service, 'the_content', 99 );
1885
-		$this->loader->add_filter( 'the_excerpt', $this->sharethis_service, 'the_excerpt', 99 );
1884
+		$this->loader->add_filter('the_content', $this->sharethis_service, 'the_content', 99);
1885
+		$this->loader->add_filter('the_excerpt', $this->sharethis_service, 'the_excerpt', 99);
1886 1886
 
1887 1887
 		// Hook the AJAX wl_jsonld action to the JSON-LD service.
1888
-		$this->loader->add_action( 'wp_ajax_nopriv_wl_jsonld', $this->jsonld_service, 'get' );
1888
+		$this->loader->add_action('wp_ajax_nopriv_wl_jsonld', $this->jsonld_service, 'get');
1889 1889
 
1890 1890
 		// Hook the `pre_get_posts` action to the `Wordlift_Category_Taxonomy_Service`
1891 1891
 		// in order to tweak WP's `WP_Query` to include entities in queries related
1892 1892
 		// to categories.
1893
-		$this->loader->add_action( 'pre_get_posts', $this->category_taxonomy_service, 'pre_get_posts', 10, 1 );
1893
+		$this->loader->add_action('pre_get_posts', $this->category_taxonomy_service, 'pre_get_posts', 10, 1);
1894 1894
 
1895 1895
 		/*
1896 1896
 		 * Hook the `pre_get_posts` action to the `Wordlift_Entity_Page_Service`
1897 1897
 		 * in order to tweak WP's `WP_Query` to show event related entities in reverse
1898 1898
 		 * order of start time.
1899 1899
 		 */
1900
-		$this->loader->add_action( 'pre_get_posts', $this->entity_page_service, 'pre_get_posts', 10, 1 );
1900
+		$this->loader->add_action('pre_get_posts', $this->entity_page_service, 'pre_get_posts', 10, 1);
1901 1901
 
1902
-		$this->loader->add_action( 'wl_async_wl_run_sparql_query', $this->sparql_service, 'run_sparql_query', 10, 1 );
1902
+		$this->loader->add_action('wl_async_wl_run_sparql_query', $this->sparql_service, 'run_sparql_query', 10, 1);
1903 1903
 
1904 1904
 		// This hook have to run before the rating service, as otherwise the post might not be a proper entity when rating is done.
1905
-		$this->loader->add_action( 'save_post', $this->entity_type_adapter, 'save_post', 9, 3 );
1905
+		$this->loader->add_action('save_post', $this->entity_type_adapter, 'save_post', 9, 3);
1906 1906
 
1907 1907
 		// Analytics Script Frontend.
1908
-		if ( $this->configuration_service->is_analytics_enable() ) {
1909
-			$this->loader->add_action( 'wp_enqueue_scripts', $this->analytics_connect, 'enqueue_scripts', 10 );
1908
+		if ($this->configuration_service->is_analytics_enable()) {
1909
+			$this->loader->add_action('wp_enqueue_scripts', $this->analytics_connect, 'enqueue_scripts', 10);
1910 1910
 		}
1911 1911
 
1912 1912
 	}
@@ -1959,11 +1959,11 @@  discard block
 block discarded – undo
1959 1959
 	 */
1960 1960
 	private function load_cli_dependencies() {
1961 1961
 
1962
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'cli/class-wordlift-push-reference-data-command.php';
1962
+		require_once plugin_dir_path(dirname(__FILE__)).'cli/class-wordlift-push-reference-data-command.php';
1963 1963
 
1964
-		$push_reference_data_command = new Wordlift_Push_Reference_Data_Command( $this->relation_service, $this->entity_service, $this->sparql_service, $this->configuration_service, $this->entity_type_service );
1964
+		$push_reference_data_command = new Wordlift_Push_Reference_Data_Command($this->relation_service, $this->entity_service, $this->sparql_service, $this->configuration_service, $this->entity_type_service);
1965 1965
 
1966
-		WP_CLI::add_command( 'wl references push', $push_reference_data_command );
1966
+		WP_CLI::add_command('wl references push', $push_reference_data_command);
1967 1967
 
1968 1968
 	}
1969 1969
 
@@ -1988,13 +1988,13 @@  discard block
 block discarded – undo
1988 1988
 		 * @since 3.27.6
1989 1989
 		 */
1990 1990
 
1991
-		wp_register_script( 'wl_enabled_blocks', false );
1991
+		wp_register_script('wl_enabled_blocks', false);
1992 1992
 
1993
-		$enabled_blocks = array( 'wordlift/products-navigator' );
1993
+		$enabled_blocks = array('wordlift/products-navigator');
1994 1994
 
1995
-		if ( apply_filters( 'wl_feature__enable__blocks', true ) ) {
1995
+		if (apply_filters('wl_feature__enable__blocks', true)) {
1996 1996
 			// To intimate JS
1997
-			$enabled_blocks = array_merge( $enabled_blocks, array(
1997
+			$enabled_blocks = array_merge($enabled_blocks, array(
1998 1998
 				'wordlift/navigator',
1999 1999
 				'wordlift/chord',
2000 2000
 				'wordlift/geomap',
@@ -2002,11 +2002,11 @@  discard block
 block discarded – undo
2002 2002
 				'wordlift/cloud',
2003 2003
 				'wordlift/vocabulary',
2004 2004
 				'wordlift/faceted-search'
2005
-			) );
2005
+			));
2006 2006
 		}
2007 2007
 
2008
-		wp_localize_script( 'wl_enabled_blocks', 'wlEnabledBlocks', $enabled_blocks );
2009
-		wp_enqueue_script( 'wl_enabled_blocks' );
2008
+		wp_localize_script('wl_enabled_blocks', 'wlEnabledBlocks', $enabled_blocks);
2009
+		wp_enqueue_script('wl_enabled_blocks');
2010 2010
 	}
2011 2011
 
2012 2012
 }
Please login to merge, or discard this patch.