PluginProbe
Tiered Pricing Table for WooCommerce / 2.1.2
Tiered Pricing Table for WooCommerce v2.1.2
8.0.2 7.1.7 7.1.5 7.1.4 7.1.1 6.5.0 6.4.0 6.1.0 trunk 1.0 1.1 2.0 2.0.1 2.0.2 2.1 2.1.1 2.1.2 2.2.0 2.2.1 2.2.2 2.2.3 2.3.0 2.3.1 2.3.2 2.3.3 All 91 releases
← All changes | freemius/includes/entities/class-fs-site.php +15 -82 8.0.2 → 2.1.2 View file →
@@ -15,12 +15,8 @@
15 15 * @var number
16 16 */
17 17 public $site_id;
18 18 /**
19 - * @var int
20 - */
21 - public $blog_id;
22 - /**
23 19 * @var number
24 20 */
25 21 public $plugin_id;
26 22 /**
@@ -43,8 +39,12 @@
43 39 * @var string E.g. en-GB
44 40 */
45 41 public $language;
46 42 /**
43 + * @var string E.g. UTF-8
44 + */
45 + public $charset;
46 + /**
47 47 * @var string Platform version (e.g WordPress version).
48 48 */
49 49 public $platform_version;
50 50 /**
@@ -85,10 +85,8 @@
85 85 /**
86 86 * @author Leo Fajardo (@leorw)
87 87 *
88 88 * @since 1.2.1.5
89 - * @deprecated Since 2.5.1
90 - * @todo Remove after a few releases.
91 89 *
92 90 * @var bool
93 91 */
94 92 public $is_disconnected = false;
@@ -103,16 +101,8 @@
103 101 *
104 102 * @var bool
105 103 */
106 104 public $is_uninstalled = false;
107 - /**
108 - * @author Edgar Melkonyan
109 - *
110 - * @since 2.4.2
111 - *
112 - * @var bool
113 - */
114 - public $is_beta;
115 105
116 106 /**
117 107 * @param stdClass|bool $site
118 108 */
@@ -179,72 +169,18 @@
179 169 // SiteGround staging.
180 170 fs_starts_with( $subdomain, 'staging' ) ||
181 171 // WPEngine staging.
182 172 fs_ends_with( $subdomain, '.staging.wpengine.com' ) ||
183 - fs_ends_with( $subdomain, '.dev.wpengine.com' ) ||
184 - fs_ends_with( $subdomain, '.wpengine.com' ) ||
185 - fs_ends_with( $subdomain, '.wpenginepowered.com' ) ||
186 173 // Pantheon
187 - ( fs_ends_with( $subdomain, 'pantheonsite.io' ) &&
188 - ( fs_starts_with( $subdomain, 'test-' ) || fs_starts_with( $subdomain, 'dev-' ) ) ) ||
174 + ( fs_ends_with($subdomain, 'pantheonsite.io') &&
175 + (fs_starts_with($subdomain, 'test-') || fs_starts_with($subdomain, 'dev-'))) ||
189 176 // Cloudways
190 177 fs_ends_with( $subdomain, '.cloudwaysapps.com' ) ||
191 178 // Kinsta
192 - (
193 - ( fs_starts_with( $subdomain, 'stg-' ) || fs_starts_with( $subdomain, 'staging-' ) || fs_starts_with( $subdomain, 'env-' ) ) &&
194 - ( fs_ends_with( $subdomain, '.kinsta.com' ) || fs_ends_with( $subdomain, '.kinsta.cloud' ) )
195 - ) ||
196 - // DesktopServer
197 - fs_ends_with( $subdomain, '.dev.cc' ) ||
198 - // Pressable
199 - fs_ends_with( $subdomain, '.mystagingwebsite.com' ) ||
200 - // WPMU DEV
201 - ( fs_ends_with( $subdomain, '.tempurl.host' ) || fs_ends_with( $subdomain, '.wpmudev.host' ) ) ||
202 - // Vendasta
203 - ( fs_ends_with( $subdomain, '.websitepro-staging.com' ) || fs_ends_with( $subdomain, '.websitepro.hosting' ) ) ||
204 - // InstaWP
205 - ( fs_ends_with( $subdomain, '.instawp.co' ) || fs_ends_with( $subdomain, '.instawp.link' ) || fs_ends_with( $subdomain, '.instawp.xyz' ) ) ||
206 - // 10Web Hosting
207 - ( fs_ends_with( $subdomain, '-dev.10web.site' ) || fs_ends_with( $subdomain, '-dev.10web.cloud' ) )
179 + (fs_ends_with($subdomain, '.kinsta.com') && fs_starts_with($subdomain, 'staging-'))
208 180 );
209 181 }
210 182
211 - /**
212 - * @author Leo Fajardo (@leorw)
213 - * @since 2.9.1
214 - *
215 - * @param string $host
216 - *
217 - * @return bool
218 - */
219 - static function is_playground_wp_environment_by_host( $host ) {
220 - // Services aimed at providing a WordPress sandbox environment.
221 - $sandbox_wp_environment_domains = array(
222 - // InstaWP
223 - 'instawp.co',
224 - 'instawp.link',
225 - 'instawp.xyz',
226 -
227 - // TasteWP
228 - 'tastewp.com',
229 -
230 - // WordPress Playground
231 - 'playground.wordpress.net',
232 - );
233 -
234 - foreach ( $sandbox_wp_environment_domains as $domain) {
235 - if (
236 - ( $host === $domain ) ||
237 - fs_ends_with( $host, '.' . $domain ) ||
238 - fs_ends_with( $host, '-' . $domain )
239 - ) {
240 - return true;
241 - }
242 - }
243 -
244 - return false;
245 - }
246 -
247 183 function is_localhost() {
248 184 return ( WP_FS__IS_LOCALHOST_FOR_SERVER || self::is_localhost_by_address( $this->url ) );
249 185 }
250 186
@@ -272,26 +208,23 @@
272 208 return is_numeric( $this->trial_plan_id );
273 209 }
274 210
275 211 /**
276 - * @author Edgar Melkonyan
212 + * @author Vova Feldman (@svovaf)
213 + * @since 2.0.0
277 214 *
278 215 * @return bool
279 216 */
280 - function is_beta() {
281 - return ( isset( $this->is_beta ) && true === $this->is_beta );
217 + function is_tracking_allowed() {
218 + return ( true !== $this->is_disconnected );
282 219 }
283 220
284 221 /**
285 - * @author Leo Fajardo (@leorw)
286 - * @since 2.5.1
222 + * @author Vova Feldman (@svovaf)
223 + * @since 2.0.0
287 224 *
288 - * @param string $site_url
289 - *
290 225 * @return bool
291 226 */
292 - function is_clone( $site_url ) {
293 - $clone_install_url = trailingslashit( fs_strip_url_protocol( $this->url ) );
294 -
295 - return ( $clone_install_url !== $site_url );
227 + function is_tracking_prohibited() {
228 + return ! $this->is_tracking_allowed();
296 229 }
297 230 }