| @@ -32,11 +32,9 @@ | ||
| 32 | 32 | * |
| 33 | 33 | * @return self Main instance. |
| 34 | 34 | */ |
| 35 | 35 | public static function instance() { |
| 36 | - if ( self::$instance === null ) { | |
| 37 | - self::$instance = new self(); | |
| 38 | - } | |
| 36 | + self::$instance ??= new self(); | |
| 39 | 37 | |
| 40 | 38 | return self::$instance; |
| 41 | 39 | } |
| 42 | 40 | |
| @@ -45,11 +43,9 @@ | ||
| 45 | 43 | * |
| 46 | 44 | * @return array List of sorted Yoast_Feature_Toggle instances. |
| 47 | 45 | */ |
| 48 | 46 | public function get_all() { |
| 49 | - if ( $this->toggles === null ) { | |
| 50 | - $this->toggles = $this->load_toggles(); | |
| 51 | - } | |
| 47 | + $this->toggles ??= $this->load_toggles(); | |
| 52 | 48 | |
| 53 | 49 | return $this->toggles; |
| 54 | 50 | } |
| 55 | 51 | |
| @@ -68,55 +64,24 @@ | ||
| 68 | 64 | 'setting' => 'semrush_integration_active', |
| 69 | 65 | 'label' => sprintf( |
| 70 | 66 | /* translators: %s: 'Semrush' */ |
| 71 | 67 | __( 'The %s integration offers suggestions and insights for keywords related to the entered focus keyphrase.', 'wordpress-seo' ), |
| 72 | - 'Semrush' | |
| 68 | + 'Semrush', | |
| 73 | 69 | ), |
| 74 | 70 | 'order' => 10, |
| 75 | 71 | ], |
| 76 | 72 | (object) [ |
| 77 | - /* translators: %s: Ryte */ | |
| 78 | - 'name' => sprintf( __( '%s integration', 'wordpress-seo' ), 'Ryte' ), | |
| 79 | - 'setting' => 'ryte_indexability', | |
| 80 | - 'label' => sprintf( | |
| 81 | - /* translators: 1: Ryte, 2: Yoast SEO */ | |
| 82 | - __( '%1$s will check weekly if your site is still indexable by search engines and %2$s will notify you when this is not the case.', 'wordpress-seo' ), | |
| 83 | - 'Ryte', | |
| 84 | - 'Yoast SEO' | |
| 85 | - ), | |
| 86 | - /* translators: %s: Ryte */ | |
| 87 | - 'read_more_label' => sprintf( __( 'Read more about how %s works.', 'wordpress-seo' ), 'Ryte ' ), | |
| 88 | - 'read_more_url' => 'https://yoa.st/2an', | |
| 89 | - 'order' => 15, | |
| 90 | - ], | |
| 91 | - (object) [ | |
| 92 | - /* translators: %s: Zapier. */ | |
| 93 | - 'name' => \sprintf( \esc_html__( '%s integration', 'wordpress-seo' ), 'Zapier' ), | |
| 94 | - 'premium' => true, | |
| 95 | - 'setting' => 'zapier_integration_active', | |
| 96 | - 'label' => \sprintf( | |
| 97 | - /* translators: 1: Yoast SEO, 2: Zapier. */ | |
| 98 | - \__( 'Set up automated actions when you publish or update your content. By connecting %1$s with %2$s, you can easily send out your published posts to any of its 2000+ destinations, such as Twitter, Facebook and more.', 'wordpress-seo' ), | |
| 99 | - 'Yoast SEO', | |
| 100 | - 'Zapier' | |
| 101 | - ), | |
| 102 | - /* translators: %s: Zapier. */ | |
| 103 | - 'read_more_label' => \sprintf( \__( 'Find out more about our %s integration.', 'wordpress-seo' ), 'Zapier' ), | |
| 104 | - 'read_more_url' => 'https://yoa.st/4et', | |
| 105 | - 'premium_url' => 'https://yoa.st/46o', | |
| 106 | - 'order' => 20, | |
| 107 | - ], | |
| 108 | - (object) [ | |
| 109 | 73 | /* translators: %s: Algolia. */ |
| 110 | - 'name' => \sprintf( \esc_html__( '%s integration', 'wordpress-seo' ), 'Algolia' ), | |
| 111 | - 'premium' => true, | |
| 112 | - 'setting' => 'algolia_integration_active', | |
| 113 | - 'label' => __( 'Improve the quality of your site search! Automatically helps your users find your cornerstone and most important content in your internal search results. It also removes noindexed posts & pages from your site’s search results.', 'wordpress-seo' ), | |
| 74 | + 'name' => sprintf( esc_html__( '%s integration', 'wordpress-seo' ), 'Algolia' ), | |
| 75 | + 'premium' => true, | |
| 76 | + 'setting' => 'algolia_integration_active', | |
| 77 | + 'label' => __( 'Improve the quality of your site search! Automatically helps your users find your cornerstone and most important content in your internal search results. It also removes noindexed posts & pages from your site’s search results.', 'wordpress-seo' ), | |
| 114 | 78 | /* translators: %s: Algolia. */ |
| 115 | - 'read_more_label' => \sprintf( \__( 'Find out more about our %s integration.', 'wordpress-seo' ), 'Algolia' ), | |
| 116 | - 'read_more_url' => 'https://yoa.st/4eu', | |
| 117 | - 'premium_url' => 'https://yoa.st/4ex', | |
| 118 | - 'order' => 25, | |
| 79 | + 'read_more_label' => sprintf( __( 'Find out more about our %s integration.', 'wordpress-seo' ), 'Algolia' ), | |
| 80 | + 'read_more_url' => 'https://yoa.st/4eu', | |
| 81 | + 'premium_url' => 'https://yoa.st/4ex', | |
| 82 | + 'premium_upsell_url' => 'https://yoa.st/get-algolia-integration', | |
| 83 | + 'order' => 25, | |
| 119 | 84 | ], |
| 120 | 85 | ]; |
| 121 | 86 | |
| 122 | 87 | /** |