Jetpack by WordPress.com - Version 8.7.0.1

Version Description

Download this release

Release Info

Developer kraftbj
Plugin Icon 128x128 Jetpack by WordPress.com
Version 8.7.0.1
Comparing to
See all releases

Code changes from version 8.7 to 8.7.0.1

class.jetpack-user-agent.php CHANGED
@@ -4,6 +4,8 @@
4
  *
5
  * @package Jetpack
6
  *
 
 
7
  * @phpcs:disable WordPress.NamingConventions.ValidVariableName.UsedPropertyNotSnakeCase
8
  * @phpcs:disable WordPress.NamingConventions.ValidVariableName.VariableNotSnakeCase
9
  * @phpcs:disable WordPress.NamingConventions.ValidVariableName.PropertyNotSnakeCase
@@ -16,7 +18,7 @@ use \Automattic\Jetpack\Device_Detection\User_Agent_Info;
16
  /**
17
  * A class providing device properties detection.
18
  *
19
- * Deprecated. Use Automattic\Jetpack\Device_Detection\User_Agent_Info instead.
20
  */
21
  class Jetpack_User_Agent_Info {
22
 
@@ -31,6 +33,8 @@ class Jetpack_User_Agent_Info {
31
  * The constructor.
32
  *
33
  * @param string $ua (Optional) User agent.
 
 
34
  */
35
  public function __construct( $ua = '' ) {
36
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info from the `automattic/jetpack-device-detection` package' );
@@ -40,6 +44,8 @@ class Jetpack_User_Agent_Info {
40
  /**
41
  * This method detects the mobile User Agent name.
42
  *
 
 
43
  * @return string The matched User Agent name, false otherwise.
44
  */
45
  public function get_mobile_user_agent_name() {
@@ -52,6 +58,8 @@ class Jetpack_User_Agent_Info {
52
  * Note that this function returns the platform name, not the UA name/type. You should use a different function
53
  * if you need to test the UA capabilites.
54
  *
 
 
55
  * @return string Name of the platform, false otherwise.
56
  */
57
  public function get_platform() {
@@ -62,6 +70,8 @@ class Jetpack_User_Agent_Info {
62
  /**
63
  * This method detects for UA which can display iPhone-optimized web content.
64
  * Includes iPhone, iPod Touch, Android, WebOS, Fennec (Firefox mobile), etc.
 
 
65
  */
66
  public function isTierIphone() {
67
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info->isTierIphone from the `automattic/jetpack-device-detection` package' );
@@ -72,6 +82,8 @@ class Jetpack_User_Agent_Info {
72
  * This method detects for UA which are likely to be capable
73
  * but may not necessarily support JavaScript.
74
  * Excludes all iPhone Tier UA.
 
 
75
  */
76
  public function isTierRichCss() {
77
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info->isTierRichCss from the `automattic/jetpack-device-detection` package' );
@@ -82,21 +94,23 @@ class Jetpack_User_Agent_Info {
82
  * Detects if the user is using a tablet.
83
  * props Corey Gilmore, BGR.com
84
  *
 
 
85
  * @return bool
86
  */
87
- public function is_tablet() {
88
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info->is_tablet from the `automattic/jetpack-device-detection` package' );
89
- return $this->ua_info->is_tablet();
90
  }
91
 
92
  /**
93
  * Detects if the current UA is the default iPhone or iPod Touch Browser.
94
  *
95
- * DEPRECATED: use is_iphone_or_ipod
96
  */
97
- public function is_iphoneOrIpod() {
98
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info->is_iphone_or_ipod from the `automattic/jetpack-device-detection` package' );
99
- return $this->ua_info->is_iphoneOrIpod();
100
  }
101
 
102
 
@@ -110,6 +124,8 @@ class Jetpack_User_Agent_Info {
110
  * Otherwise those browsers will be 'catched' by the iphone string.
111
  *
112
  * @param string $type Type of iPhone detection.
 
 
113
  */
114
  public static function is_iphone_or_ipod( $type = 'iphone-any' ) {
115
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_iphone_or_ipod from the `automattic/jetpack-device-detection` package' );
@@ -121,6 +137,8 @@ class Jetpack_User_Agent_Info {
121
  *
122
  * The User-Agent string in Chrome for iOS is the same as the Mobile Safari User-Agent, with CriOS/<ChromeRevision> instead of Version/<VersionNum>.
123
  * - Mozilla/5.0 (iPhone; U; CPU iPhone OS 5_1_1 like Mac OS X; en) AppleWebKit/534.46.0 (KHTML, like Gecko) CriOS/19.0.1084.60 Mobile/9B206 Safari/7534.48.3
 
 
124
  */
125
  public static function is_chrome_for_iOS() {
126
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_chrome_for_iOS from the `automattic/jetpack-device-detection` package' );
@@ -132,6 +150,8 @@ class Jetpack_User_Agent_Info {
132
  *
133
  * Mozilla/5.0 (iPhone; U; CPU iPhone OS 4_3_5 like Mac OS X; nb-no) AppleWebKit/533.17.9 (KHTML, like Gecko) Mobile/8L1 Twitter for iPhone
134
  * Mozilla/5.0 (iPhone; CPU iPhone OS 5_1_1 like Mac OS X) AppleWebKit/534.46 (KHTML, like Gecko) Mobile/9B206 Twitter for iPhone
 
 
135
  */
136
  public static function is_twitter_for_iphone() {
137
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_twitter_for_iphone from the `automattic/jetpack-device-detection` package' );
@@ -143,6 +163,8 @@ class Jetpack_User_Agent_Info {
143
  *
144
  * Old version 4.X - Mozilla/5.0 (iPad; U; CPU OS 4_3_5 like Mac OS X; en-us) AppleWebKit/533.17.9 (KHTML, like Gecko) Mobile/8L1 Twitter for iPad
145
  * Ver 5.0 or Higher - Mozilla/5.0 (iPad; CPU OS 5_1_1 like Mac OS X) AppleWebKit/534.46 (KHTML, like Gecko) Mobile/9B206 Twitter for iPhone
 
 
146
  */
147
  public static function is_twitter_for_ipad() {
148
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_twitter_for_ipad from the `automattic/jetpack-device-detection` package' );
@@ -154,6 +176,8 @@ class Jetpack_User_Agent_Info {
154
  * - Facebook 4020.0 (iPhone; iPhone OS 5.0.1; fr_FR)
155
  * - Mozilla/5.0 (iPhone; U; CPU iPhone OS 5_0 like Mac OS X; en_US) AppleWebKit (KHTML, like Gecko) Mobile [FBAN/FBForIPhone;FBAV/4.0.2;FBBV/4020.0;FBDV/iPhone3,1;FBMD/iPhone;FBSN/iPhone OS;FBSV/5.0;FBSS/2; FBCR/O2;FBID/phone;FBLC/en_US;FBSF/2.0]
156
  * - Mozilla/5.0 (iPhone; CPU iPhone OS 5_1_1 like Mac OS X) AppleWebKit/534.46 (KHTML, like Gecko) Mobile/9B206 [FBAN/FBIOS;FBAV/5.0;FBBV/47423;FBDV/iPhone3,1;FBMD/iPhone;FBSN/iPhone OS;FBSV/5.1.1;FBSS/2; FBCR/3ITA;FBID/phone;FBLC/en_US]
 
 
157
  */
158
  public static function is_facebook_for_iphone() {
159
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_facebook_for_iphone from the `automattic/jetpack-device-detection` package' );
@@ -165,6 +189,8 @@ class Jetpack_User_Agent_Info {
165
  * - Facebook 4020.0 (iPad; iPhone OS 5.0.1; en_US)
166
  * - Mozilla/5.0 (iPad; U; CPU iPhone OS 5_0 like Mac OS X; en_US) AppleWebKit (KHTML, like Gecko) Mobile [FBAN/FBForIPhone;FBAV/4.0.2;FBBV/4020.0;FBDV/iPad2,1;FBMD/iPad;FBSN/iPhone OS;FBSV/5.0;FBSS/1; FBCR/;FBID/tablet;FBLC/en_US;FBSF/1.0]
167
  * - Mozilla/5.0 (iPad; CPU OS 6_0 like Mac OS X) AppleWebKit/536.26 (KHTML, like Gecko) Mobile/10A403 [FBAN/FBIOS;FBAV/5.0;FBBV/47423;FBDV/iPad2,1;FBMD/iPad;FBSN/iPhone OS;FBSV/6.0;FBSS/1; FBCR/;FBID/tablet;FBLC/en_US]
 
 
168
  */
169
  public static function is_facebook_for_ipad() {
170
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_facebook_for_ipad from the `automattic/jetpack-device-detection` package' );
@@ -172,7 +198,9 @@ class Jetpack_User_Agent_Info {
172
  }
173
 
174
  /**
175
- * Detects if the current UA is WordPress for iOS
 
 
176
  */
177
  public static function is_wordpress_for_ios() {
178
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_wordpress_for_ios from the `automattic/jetpack-device-detection` package' );
@@ -188,6 +216,8 @@ class Jetpack_User_Agent_Info {
188
  * Otherwise those browsers will be 'catched' by the ipad string.
189
  *
190
  * @param string $type iPad type.
 
 
191
  */
192
  public static function is_ipad( $type = 'ipad-any' ) {
193
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_ipad from the `automattic/jetpack-device-detection` package' );
@@ -200,6 +230,8 @@ class Jetpack_User_Agent_Info {
200
  * See http://www.useragentstring.com/pages/Fennec/
201
  * Mozilla/5.0 (Windows NT 6.1; WOW64; rv:2.1.1) Gecko/20110415 Firefox/4.0.2pre Fennec/4.0.1
202
  * Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1b2pre) Gecko/20081015 Fennec/1.0a1
 
 
203
  */
204
  public static function is_firefox_mobile() {
205
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_firefox_mobile from the `automattic/jetpack-device-detection` package' );
@@ -212,6 +244,8 @@ class Jetpack_User_Agent_Info {
212
  * See https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/User-Agent/Firefox
213
  * Mozilla/5.0 (platform; rv:geckoversion) Gecko/geckotrail Firefox/firefoxversion
214
  * The platform section will include 'Mobile' for phones and 'Tablet' for tablets.
 
 
215
  */
216
  public static function is_firefox_desktop() {
217
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_firefox_desktop from the `automattic/jetpack-device-detection` package' );
@@ -222,6 +256,8 @@ class Jetpack_User_Agent_Info {
222
  * Detects if the current browser is FirefoxOS Native browser
223
  *
224
  * Mozilla/5.0 (Mobile; rv:14.0) Gecko/14.0 Firefox/14.0
 
 
225
  */
226
  public static function is_firefox_os() {
227
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_firefox_os from the `automattic/jetpack-device-detection` package' );
@@ -239,6 +275,8 @@ class Jetpack_User_Agent_Info {
239
  *
240
  * Opera/9.80 (Windows NT 6.1; Opera Mobi/14316; U; en) Presto/2.7.81 Version/11.00"
241
  * Opera/9.50 (Nintendo DSi; Opera/507; U; en-US)
 
 
242
  */
243
  public static function is_opera_mobile() {
244
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_opera_mobile from the `automattic/jetpack-device-detection` package' );
@@ -256,6 +294,8 @@ class Jetpack_User_Agent_Info {
256
  * Opera/9.80 (J2ME/iPhone;Opera Mini/5.0.019802/886; U; ja) Presto/2.4.15
257
  * Opera/9.80 (Series 60; Opera Mini/5.1.22783/23.334; U; en) Presto/2.5.25 Version/10.54
258
  * Opera/9.80 (BlackBerry; Opera Mini/5.1.22303/22.387; U; en) Presto/2.5.25 Version/10.54
 
 
259
  */
260
  public static function is_opera_mini() {
261
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_opera_mini from the `automattic/jetpack-device-detection` package' );
@@ -265,6 +305,8 @@ class Jetpack_User_Agent_Info {
265
  /**
266
  * Detects if the current browser is Opera Mini, but not on a smart device OS(Android, iOS, etc)
267
  * Used to send users on dumb devices to m.wor
 
 
268
  */
269
  public static function is_opera_mini_dumb() {
270
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_opera_mini_dumb from the `automattic/jetpack-device-detection` package' );
@@ -273,10 +315,11 @@ class Jetpack_User_Agent_Info {
273
 
274
  /**
275
  * Detects if the current browser is Opera Mobile or Mini.
276
- * DEPRECATED: use is_opera_mobile or is_opera_mini
277
  *
278
  * Opera Mini 5 Beta: Opera/9.80 (J2ME/MIDP; Opera Mini/5.0.15650/756; U; en) Presto/2.2.0
279
  * Opera Mini 8: Opera/8.01 (J2ME/MIDP; Opera Mini/3.0.6306/1528; en; U; ssr)
 
 
280
  */
281
  public static function is_OperaMobile() {
282
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_opera_mini() or \Automattic\Jetpack\Device_Detection\User_Agent_Info::is_opera_mobile() from the `automattic/jetpack-device-detection` package' );
@@ -286,6 +329,8 @@ class Jetpack_User_Agent_Info {
286
  /**
287
  * Detects if the current browser is a Windows Phone 7 device.
288
  * ex: Mozilla/4.0 (compatible; MSIE 7.0; Windows Phone OS 7.0; Trident/3.1; IEMobile/7.0; LG; GW910)
 
 
289
  */
290
  public static function is_WindowsPhone7() {
291
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_WindowsPhone7 from the `automattic/jetpack-device-detection` package' );
@@ -295,6 +340,8 @@ class Jetpack_User_Agent_Info {
295
  /**
296
  * Detects if the current browser is a Windows Phone 8 device.
297
  * ex: Mozilla/5.0 (compatible; MSIE 10.0; Windows Phone 8.0; Trident/6.0; ARM; Touch; IEMobile/10.0; <Manufacturer>; <Device> [;<Operator>])
 
 
298
  */
299
  public static function is_windows_phone_8() {
300
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_windows_phone_8 from the `automattic/jetpack-device-detection` package' );
@@ -307,6 +354,8 @@ class Jetpack_User_Agent_Info {
307
  *
308
  * Ex1: Mozilla/5.0 (webOS/1.4.0; U; en-US) AppleWebKit/532.2 (KHTML, like Gecko) Version/1.0 Safari/532.2 Pre/1.1
309
  * Ex2: Mozilla/5.0 (webOS/1.4.0; U; en-US) AppleWebKit/532.2 (KHTML, like Gecko) Version/1.0 Safari/532.2 Pixi/1.1
 
 
310
  */
311
  public static function is_PalmWebOS() {
312
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_PalmWebOS from the `automattic/jetpack-device-detection` package' );
@@ -318,6 +367,8 @@ class Jetpack_User_Agent_Info {
318
  *
319
  * TouchPad Emulator: Mozilla/5.0 (hp-desktop; Linux; hpwOS/2.0; U; it-IT) AppleWebKit/534.6 (KHTML, like Gecko) wOSBrowser/233.70 Safari/534.6 Desktop/1.0
320
  * TouchPad: Mozilla/5.0 (hp-tablet; Linux; hpwOS/3.0.0; U; en-US) AppleWebKit/534.6 (KHTML, like Gecko) wOSBrowser/233.70 Safari/534.6 TouchPad/1.0
 
 
321
  */
322
  public static function is_TouchPad() {
323
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_TouchPad from the `automattic/jetpack-device-detection` package' );
@@ -333,6 +384,8 @@ class Jetpack_User_Agent_Info {
333
  * 7.0 Browser (Nokia 5800 XpressMusic (v21.0.025)) : Mozilla/5.0 (SymbianOS/9.4; U; Series60/5.0 Nokia5800d-1/21.0.025; Profile/MIDP-2.1 Configuration/CLDC-1.1 ) AppleWebKit/413 (KHTML, like Gecko) Safari/413
334
  *
335
  * Browser 7.1 (Nokia N97 (v12.0.024)) : Mozilla/5.0 (SymbianOS/9.4; Series60/5.0 NokiaN97-1/12.0.024; Profile/MIDP-2.1 Configuration/CLDC-1.1; en-us) AppleWebKit/525 (KHTML, like Gecko) BrowserNG/7.1.12344
 
 
336
  */
337
  public static function is_S60_OSSBrowser() {
338
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_S60_OSSBrowser from the `automattic/jetpack-device-detection` package' );
@@ -341,6 +394,8 @@ class Jetpack_User_Agent_Info {
341
 
342
  /**
343
  * Detects if the device platform is the Symbian Series 60.
 
 
344
  */
345
  public static function is_symbian_platform() {
346
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_symbian_platform from the `automattic/jetpack-device-detection` package' );
@@ -351,6 +406,8 @@ class Jetpack_User_Agent_Info {
351
  * Detects if the device platform is the Symbian Series 40.
352
  * Nokia Browser for Series 40 is a proxy based browser, previously known as Ovi Browser.
353
  * This browser will report 'NokiaBrowser' in the header, however some older version will also report 'OviBrowser'.
 
 
354
  */
355
  public static function is_symbian_s40_platform() {
356
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_symbian_s40_platform from the `automattic/jetpack-device-detection` package' );
@@ -360,6 +417,8 @@ class Jetpack_User_Agent_Info {
360
  /**
361
  * Returns if the device belongs to J2ME capable family.
362
  *
 
 
363
  * @return bool
364
  */
365
  public static function is_J2ME_platform() {
@@ -370,6 +429,8 @@ class Jetpack_User_Agent_Info {
370
 
371
  /**
372
  * Detects if the current UA is on one of the Maemo-based Nokia Internet Tablets.
 
 
373
  */
374
  public static function is_MaemoTablet() {
375
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_MaemoTablet from the `automattic/jetpack-device-detection` package' );
@@ -378,6 +439,8 @@ class Jetpack_User_Agent_Info {
378
 
379
  /**
380
  * Detects if the current UA is a MeeGo device (Nokia Smartphone).
 
 
381
  */
382
  public static function is_MeeGo() {
383
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_MeeGo from the `automattic/jetpack-device-detection` package' );
@@ -387,6 +450,8 @@ class Jetpack_User_Agent_Info {
387
 
388
  /**
389
  * The is_webkit() method can be used to check the User Agent for an webkit generic browser.
 
 
390
  */
391
  public static function is_webkit() {
392
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_webkit from the `automattic/jetpack-device-detection` package' );
@@ -396,6 +461,8 @@ class Jetpack_User_Agent_Info {
396
  /**
397
  * Detects if the current browser is the Native Android browser.
398
  *
 
 
399
  * @return boolean true if the browser is Android otherwise false
400
  */
401
  public static function is_android() {
@@ -408,6 +475,8 @@ class Jetpack_User_Agent_Info {
408
  * Detects if the current browser is the Native Android Tablet browser.
409
  * Assumes 'Android' should be in the user agent, but not 'mobile'
410
  *
 
 
411
  * @return boolean true if the browser is Android and not 'mobile' otherwise false
412
  */
413
  public static function is_android_tablet() {
@@ -421,6 +490,8 @@ class Jetpack_User_Agent_Info {
421
  * Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10_6_3; en-us; Silk/1.1.0-84) AppleWebKit/533.16 (KHTML, like Gecko) Version/5.0 Safari/533.16 Silk-Accelerated=true
422
  * Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10_6_3; en-us; Silk/1.1.0-84) AppleWebKit/533.16 (KHTML, like Gecko) Version/5.0 Safari/533.16 Silk-Accelerated=false
423
  *
 
 
424
  * @return boolean true if the browser is Kindle Fire Native browser otherwise false
425
  */
426
  public static function is_kindle_fire() {
@@ -433,6 +504,8 @@ class Jetpack_User_Agent_Info {
433
  *
434
  * Mozilla/5.0 (X11; U; Linux armv7l like Android; en-us) AppleWebKit/531.2+ (KHTML, like Gecko) Version/5.0 Safari/533.2+ Kindle/3.0+
435
  *
 
 
436
  * @return boolean true if the browser is Kindle monochrome Native browser otherwise false
437
  */
438
  public static function is_kindle_touch() {
@@ -443,6 +516,8 @@ class Jetpack_User_Agent_Info {
443
 
444
  /**
445
  * Detect if user agent is the WordPress.com Windows 8 app (used ONLY on the custom oauth stylesheet)
 
 
446
  */
447
  public static function is_windows8_auth() {
448
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_windows8_auth from the `automattic/jetpack-device-detection` package' );
@@ -451,6 +526,8 @@ class Jetpack_User_Agent_Info {
451
 
452
  /**
453
  * Detect if user agent is the WordPress.com Windows 8 app.
 
 
454
  */
455
  public static function is_wordpress_for_win8() {
456
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_wordpress_for_win8 from the `automattic/jetpack-device-detection` package' );
@@ -459,6 +536,8 @@ class Jetpack_User_Agent_Info {
459
 
460
  /**
461
  * Detect if user agent is the WordPress.com Desktop app.
 
 
462
  */
463
  public static function is_wordpress_desktop_app() {
464
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_wordpress_desktop_app from the `automattic/jetpack-device-detection` package' );
@@ -469,6 +548,8 @@ class Jetpack_User_Agent_Info {
469
  * The is_blackberry_tablet() method can be used to check the User Agent for a RIM blackberry tablet.
470
  * The user agent of the BlackBerry® Tablet OS follows a format similar to the following:
471
  * Mozilla/5.0 (PlayBook; U; RIM Tablet OS 1.0.0; en-US) AppleWebKit/534.8+ (KHTML, like Gecko) Version/0.0.1 Safari/534.8+
 
 
472
  */
473
  public static function is_blackberry_tablet() {
474
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_blackberry_tablet from the `automattic/jetpack-device-detection` package' );
@@ -478,6 +559,8 @@ class Jetpack_User_Agent_Info {
478
  /**
479
  * The is_blackbeberry() method can be used to check the User Agent for a blackberry device.
480
  * Note that opera mini on BB matches this rule.
 
 
481
  */
482
  public static function is_blackbeberry() {
483
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_blackbeberry from the `automattic/jetpack-device-detection` package' );
@@ -486,6 +569,8 @@ class Jetpack_User_Agent_Info {
486
 
487
  /**
488
  * The is_blackberry_10() method can be used to check the User Agent for a BlackBerry 10 device.
 
 
489
  */
490
  public static function is_blackberry_10() {
491
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_blackberry_10 from the `automattic/jetpack-device-detection` package' );
@@ -505,8 +590,9 @@ class Jetpack_User_Agent_Info {
505
  * - blackberry-4.6
506
  * - blackberry-4.5
507
  *
508
- * @return string Version of the BB OS.
509
- * If version is not found, get_blackbeberry_OS_version will return boolean false.
 
510
  */
511
  public static function get_blackbeberry_OS_version() {
512
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::get_blackbeberry_OS_version from the `automattic/jetpack-device-detection` package' );
@@ -523,8 +609,9 @@ class Jetpack_User_Agent_Info {
523
  * - blackberry-4.7
524
  * - blackberry-4.6
525
  *
526
- * @return string Type of the BB browser.
527
- * If browser's version is not found, detect_blackbeberry_browser_version will return boolean false.
 
528
  */
529
  public static function detect_blackberry_browser_version() {
530
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::detect_blackberry_browser_version from the `automattic/jetpack-device-detection` package' );
@@ -534,6 +621,8 @@ class Jetpack_User_Agent_Info {
534
  /**
535
  * Checks if a visitor is coming from one of the WordPress mobile apps.
536
  *
 
 
537
  * @return bool
538
  */
539
  public static function is_mobile_app() {
@@ -546,6 +635,8 @@ class Jetpack_User_Agent_Info {
546
  *
547
  * Example: Mozilla/5.0 (Nintendo 3DS; U; ; en) Version/1.7498.US
548
  * can differ in language, version and region
 
 
549
  */
550
  public static function is_Nintendo_3DS() {
551
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_Nintendo_3DS from the `automattic/jetpack-device-detection` package' );
@@ -555,6 +646,8 @@ class Jetpack_User_Agent_Info {
555
  /**
556
  * Was the current request made by a known bot?
557
  *
 
 
558
  * @return boolean
559
  */
560
  public static function is_bot() {
@@ -568,6 +661,8 @@ class Jetpack_User_Agent_Info {
568
  *
569
  * @param string $ua A user-agent string.
570
  *
 
 
571
  * @return boolean
572
  */
573
  public static function is_bot_user_agent( $ua = null ) {
4
  *
5
  * @package Jetpack
6
  *
7
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
8
+ *
9
  * @phpcs:disable WordPress.NamingConventions.ValidVariableName.UsedPropertyNotSnakeCase
10
  * @phpcs:disable WordPress.NamingConventions.ValidVariableName.VariableNotSnakeCase
11
  * @phpcs:disable WordPress.NamingConventions.ValidVariableName.PropertyNotSnakeCase
18
  /**
19
  * A class providing device properties detection.
20
  *
21
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
22
  */
23
  class Jetpack_User_Agent_Info {
24
 
33
  * The constructor.
34
  *
35
  * @param string $ua (Optional) User agent.
36
+ *
37
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
38
  */
39
  public function __construct( $ua = '' ) {
40
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info from the `automattic/jetpack-device-detection` package' );
44
  /**
45
  * This method detects the mobile User Agent name.
46
  *
47
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
48
+ *
49
  * @return string The matched User Agent name, false otherwise.
50
  */
51
  public function get_mobile_user_agent_name() {
58
  * Note that this function returns the platform name, not the UA name/type. You should use a different function
59
  * if you need to test the UA capabilites.
60
  *
61
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
62
+ *
63
  * @return string Name of the platform, false otherwise.
64
  */
65
  public function get_platform() {
70
  /**
71
  * This method detects for UA which can display iPhone-optimized web content.
72
  * Includes iPhone, iPod Touch, Android, WebOS, Fennec (Firefox mobile), etc.
73
+ *
74
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
75
  */
76
  public function isTierIphone() {
77
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info->isTierIphone from the `automattic/jetpack-device-detection` package' );
82
  * This method detects for UA which are likely to be capable
83
  * but may not necessarily support JavaScript.
84
  * Excludes all iPhone Tier UA.
85
+ *
86
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
87
  */
88
  public function isTierRichCss() {
89
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info->isTierRichCss from the `automattic/jetpack-device-detection` package' );
94
  * Detects if the user is using a tablet.
95
  * props Corey Gilmore, BGR.com
96
  *
97
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
98
+ *
99
  * @return bool
100
  */
101
+ public static function is_tablet() {
102
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info->is_tablet from the `automattic/jetpack-device-detection` package' );
103
+ return ( new User_Agent_Info() )->is_tablet();
104
  }
105
 
106
  /**
107
  * Detects if the current UA is the default iPhone or iPod Touch Browser.
108
  *
109
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
110
  */
111
+ public static function is_iphoneOrIpod() {
112
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info->is_iphone_or_ipod from the `automattic/jetpack-device-detection` package' );
113
+ return ( new User_Agent_Info() )->is_iphoneOrIpod();
114
  }
115
 
116
 
124
  * Otherwise those browsers will be 'catched' by the iphone string.
125
  *
126
  * @param string $type Type of iPhone detection.
127
+ *
128
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
129
  */
130
  public static function is_iphone_or_ipod( $type = 'iphone-any' ) {
131
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_iphone_or_ipod from the `automattic/jetpack-device-detection` package' );
137
  *
138
  * The User-Agent string in Chrome for iOS is the same as the Mobile Safari User-Agent, with CriOS/<ChromeRevision> instead of Version/<VersionNum>.
139
  * - Mozilla/5.0 (iPhone; U; CPU iPhone OS 5_1_1 like Mac OS X; en) AppleWebKit/534.46.0 (KHTML, like Gecko) CriOS/19.0.1084.60 Mobile/9B206 Safari/7534.48.3
140
+ *
141
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
142
  */
143
  public static function is_chrome_for_iOS() {
144
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_chrome_for_iOS from the `automattic/jetpack-device-detection` package' );
150
  *
151
  * Mozilla/5.0 (iPhone; U; CPU iPhone OS 4_3_5 like Mac OS X; nb-no) AppleWebKit/533.17.9 (KHTML, like Gecko) Mobile/8L1 Twitter for iPhone
152
  * Mozilla/5.0 (iPhone; CPU iPhone OS 5_1_1 like Mac OS X) AppleWebKit/534.46 (KHTML, like Gecko) Mobile/9B206 Twitter for iPhone
153
+ *
154
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
155
  */
156
  public static function is_twitter_for_iphone() {
157
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_twitter_for_iphone from the `automattic/jetpack-device-detection` package' );
163
  *
164
  * Old version 4.X - Mozilla/5.0 (iPad; U; CPU OS 4_3_5 like Mac OS X; en-us) AppleWebKit/533.17.9 (KHTML, like Gecko) Mobile/8L1 Twitter for iPad
165
  * Ver 5.0 or Higher - Mozilla/5.0 (iPad; CPU OS 5_1_1 like Mac OS X) AppleWebKit/534.46 (KHTML, like Gecko) Mobile/9B206 Twitter for iPhone
166
+ *
167
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
168
  */
169
  public static function is_twitter_for_ipad() {
170
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_twitter_for_ipad from the `automattic/jetpack-device-detection` package' );
176
  * - Facebook 4020.0 (iPhone; iPhone OS 5.0.1; fr_FR)
177
  * - Mozilla/5.0 (iPhone; U; CPU iPhone OS 5_0 like Mac OS X; en_US) AppleWebKit (KHTML, like Gecko) Mobile [FBAN/FBForIPhone;FBAV/4.0.2;FBBV/4020.0;FBDV/iPhone3,1;FBMD/iPhone;FBSN/iPhone OS;FBSV/5.0;FBSS/2; FBCR/O2;FBID/phone;FBLC/en_US;FBSF/2.0]
178
  * - Mozilla/5.0 (iPhone; CPU iPhone OS 5_1_1 like Mac OS X) AppleWebKit/534.46 (KHTML, like Gecko) Mobile/9B206 [FBAN/FBIOS;FBAV/5.0;FBBV/47423;FBDV/iPhone3,1;FBMD/iPhone;FBSN/iPhone OS;FBSV/5.1.1;FBSS/2; FBCR/3ITA;FBID/phone;FBLC/en_US]
179
+ *
180
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
181
  */
182
  public static function is_facebook_for_iphone() {
183
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_facebook_for_iphone from the `automattic/jetpack-device-detection` package' );
189
  * - Facebook 4020.0 (iPad; iPhone OS 5.0.1; en_US)
190
  * - Mozilla/5.0 (iPad; U; CPU iPhone OS 5_0 like Mac OS X; en_US) AppleWebKit (KHTML, like Gecko) Mobile [FBAN/FBForIPhone;FBAV/4.0.2;FBBV/4020.0;FBDV/iPad2,1;FBMD/iPad;FBSN/iPhone OS;FBSV/5.0;FBSS/1; FBCR/;FBID/tablet;FBLC/en_US;FBSF/1.0]
191
  * - Mozilla/5.0 (iPad; CPU OS 6_0 like Mac OS X) AppleWebKit/536.26 (KHTML, like Gecko) Mobile/10A403 [FBAN/FBIOS;FBAV/5.0;FBBV/47423;FBDV/iPad2,1;FBMD/iPad;FBSN/iPhone OS;FBSV/6.0;FBSS/1; FBCR/;FBID/tablet;FBLC/en_US]
192
+ *
193
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
194
  */
195
  public static function is_facebook_for_ipad() {
196
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_facebook_for_ipad from the `automattic/jetpack-device-detection` package' );
198
  }
199
 
200
  /**
201
+ * Detects if the current UA is WordPress for iOS.
202
+ *
203
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
204
  */
205
  public static function is_wordpress_for_ios() {
206
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_wordpress_for_ios from the `automattic/jetpack-device-detection` package' );
216
  * Otherwise those browsers will be 'catched' by the ipad string.
217
  *
218
  * @param string $type iPad type.
219
+ *
220
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
221
  */
222
  public static function is_ipad( $type = 'ipad-any' ) {
223
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_ipad from the `automattic/jetpack-device-detection` package' );
230
  * See http://www.useragentstring.com/pages/Fennec/
231
  * Mozilla/5.0 (Windows NT 6.1; WOW64; rv:2.1.1) Gecko/20110415 Firefox/4.0.2pre Fennec/4.0.1
232
  * Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1b2pre) Gecko/20081015 Fennec/1.0a1
233
+ *
234
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
235
  */
236
  public static function is_firefox_mobile() {
237
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_firefox_mobile from the `automattic/jetpack-device-detection` package' );
244
  * See https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/User-Agent/Firefox
245
  * Mozilla/5.0 (platform; rv:geckoversion) Gecko/geckotrail Firefox/firefoxversion
246
  * The platform section will include 'Mobile' for phones and 'Tablet' for tablets.
247
+ *
248
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
249
  */
250
  public static function is_firefox_desktop() {
251
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_firefox_desktop from the `automattic/jetpack-device-detection` package' );
256
  * Detects if the current browser is FirefoxOS Native browser
257
  *
258
  * Mozilla/5.0 (Mobile; rv:14.0) Gecko/14.0 Firefox/14.0
259
+ *
260
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
261
  */
262
  public static function is_firefox_os() {
263
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_firefox_os from the `automattic/jetpack-device-detection` package' );
275
  *
276
  * Opera/9.80 (Windows NT 6.1; Opera Mobi/14316; U; en) Presto/2.7.81 Version/11.00"
277
  * Opera/9.50 (Nintendo DSi; Opera/507; U; en-US)
278
+ *
279
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
280
  */
281
  public static function is_opera_mobile() {
282
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_opera_mobile from the `automattic/jetpack-device-detection` package' );
294
  * Opera/9.80 (J2ME/iPhone;Opera Mini/5.0.019802/886; U; ja) Presto/2.4.15
295
  * Opera/9.80 (Series 60; Opera Mini/5.1.22783/23.334; U; en) Presto/2.5.25 Version/10.54
296
  * Opera/9.80 (BlackBerry; Opera Mini/5.1.22303/22.387; U; en) Presto/2.5.25 Version/10.54
297
+ *
298
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
299
  */
300
  public static function is_opera_mini() {
301
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_opera_mini from the `automattic/jetpack-device-detection` package' );
305
  /**
306
  * Detects if the current browser is Opera Mini, but not on a smart device OS(Android, iOS, etc)
307
  * Used to send users on dumb devices to m.wor
308
+ *
309
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
310
  */
311
  public static function is_opera_mini_dumb() {
312
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_opera_mini_dumb from the `automattic/jetpack-device-detection` package' );
315
 
316
  /**
317
  * Detects if the current browser is Opera Mobile or Mini.
 
318
  *
319
  * Opera Mini 5 Beta: Opera/9.80 (J2ME/MIDP; Opera Mini/5.0.15650/756; U; en) Presto/2.2.0
320
  * Opera Mini 8: Opera/8.01 (J2ME/MIDP; Opera Mini/3.0.6306/1528; en; U; ssr)
321
+ *
322
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
323
  */
324
  public static function is_OperaMobile() {
325
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_opera_mini() or \Automattic\Jetpack\Device_Detection\User_Agent_Info::is_opera_mobile() from the `automattic/jetpack-device-detection` package' );
329
  /**
330
  * Detects if the current browser is a Windows Phone 7 device.
331
  * ex: Mozilla/4.0 (compatible; MSIE 7.0; Windows Phone OS 7.0; Trident/3.1; IEMobile/7.0; LG; GW910)
332
+ *
333
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
334
  */
335
  public static function is_WindowsPhone7() {
336
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_WindowsPhone7 from the `automattic/jetpack-device-detection` package' );
340
  /**
341
  * Detects if the current browser is a Windows Phone 8 device.
342
  * ex: Mozilla/5.0 (compatible; MSIE 10.0; Windows Phone 8.0; Trident/6.0; ARM; Touch; IEMobile/10.0; <Manufacturer>; <Device> [;<Operator>])
343
+ *
344
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
345
  */
346
  public static function is_windows_phone_8() {
347
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_windows_phone_8 from the `automattic/jetpack-device-detection` package' );
354
  *
355
  * Ex1: Mozilla/5.0 (webOS/1.4.0; U; en-US) AppleWebKit/532.2 (KHTML, like Gecko) Version/1.0 Safari/532.2 Pre/1.1
356
  * Ex2: Mozilla/5.0 (webOS/1.4.0; U; en-US) AppleWebKit/532.2 (KHTML, like Gecko) Version/1.0 Safari/532.2 Pixi/1.1
357
+ *
358
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
359
  */
360
  public static function is_PalmWebOS() {
361
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_PalmWebOS from the `automattic/jetpack-device-detection` package' );
367
  *
368
  * TouchPad Emulator: Mozilla/5.0 (hp-desktop; Linux; hpwOS/2.0; U; it-IT) AppleWebKit/534.6 (KHTML, like Gecko) wOSBrowser/233.70 Safari/534.6 Desktop/1.0
369
  * TouchPad: Mozilla/5.0 (hp-tablet; Linux; hpwOS/3.0.0; U; en-US) AppleWebKit/534.6 (KHTML, like Gecko) wOSBrowser/233.70 Safari/534.6 TouchPad/1.0
370
+ *
371
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
372
  */
373
  public static function is_TouchPad() {
374
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_TouchPad from the `automattic/jetpack-device-detection` package' );
384
  * 7.0 Browser (Nokia 5800 XpressMusic (v21.0.025)) : Mozilla/5.0 (SymbianOS/9.4; U; Series60/5.0 Nokia5800d-1/21.0.025; Profile/MIDP-2.1 Configuration/CLDC-1.1 ) AppleWebKit/413 (KHTML, like Gecko) Safari/413
385
  *
386
  * Browser 7.1 (Nokia N97 (v12.0.024)) : Mozilla/5.0 (SymbianOS/9.4; Series60/5.0 NokiaN97-1/12.0.024; Profile/MIDP-2.1 Configuration/CLDC-1.1; en-us) AppleWebKit/525 (KHTML, like Gecko) BrowserNG/7.1.12344
387
+ *
388
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
389
  */
390
  public static function is_S60_OSSBrowser() {
391
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_S60_OSSBrowser from the `automattic/jetpack-device-detection` package' );
394
 
395
  /**
396
  * Detects if the device platform is the Symbian Series 60.
397
+ *
398
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
399
  */
400
  public static function is_symbian_platform() {
401
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_symbian_platform from the `automattic/jetpack-device-detection` package' );
406
  * Detects if the device platform is the Symbian Series 40.
407
  * Nokia Browser for Series 40 is a proxy based browser, previously known as Ovi Browser.
408
  * This browser will report 'NokiaBrowser' in the header, however some older version will also report 'OviBrowser'.
409
+ *
410
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
411
  */
412
  public static function is_symbian_s40_platform() {
413
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_symbian_s40_platform from the `automattic/jetpack-device-detection` package' );
417
  /**
418
  * Returns if the device belongs to J2ME capable family.
419
  *
420
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
421
+ *
422
  * @return bool
423
  */
424
  public static function is_J2ME_platform() {
429
 
430
  /**
431
  * Detects if the current UA is on one of the Maemo-based Nokia Internet Tablets.
432
+ *
433
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
434
  */
435
  public static function is_MaemoTablet() {
436
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_MaemoTablet from the `automattic/jetpack-device-detection` package' );
439
 
440
  /**
441
  * Detects if the current UA is a MeeGo device (Nokia Smartphone).
442
+ *
443
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
444
  */
445
  public static function is_MeeGo() {
446
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_MeeGo from the `automattic/jetpack-device-detection` package' );
450
 
451
  /**
452
  * The is_webkit() method can be used to check the User Agent for an webkit generic browser.
453
+ *
454
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
455
  */
456
  public static function is_webkit() {
457
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_webkit from the `automattic/jetpack-device-detection` package' );
461
  /**
462
  * Detects if the current browser is the Native Android browser.
463
  *
464
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
465
+ *
466
  * @return boolean true if the browser is Android otherwise false
467
  */
468
  public static function is_android() {
475
  * Detects if the current browser is the Native Android Tablet browser.
476
  * Assumes 'Android' should be in the user agent, but not 'mobile'
477
  *
478
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
479
+ *
480
  * @return boolean true if the browser is Android and not 'mobile' otherwise false
481
  */
482
  public static function is_android_tablet() {
490
  * Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10_6_3; en-us; Silk/1.1.0-84) AppleWebKit/533.16 (KHTML, like Gecko) Version/5.0 Safari/533.16 Silk-Accelerated=true
491
  * Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10_6_3; en-us; Silk/1.1.0-84) AppleWebKit/533.16 (KHTML, like Gecko) Version/5.0 Safari/533.16 Silk-Accelerated=false
492
  *
493
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
494
+ *
495
  * @return boolean true if the browser is Kindle Fire Native browser otherwise false
496
  */
497
  public static function is_kindle_fire() {
504
  *
505
  * Mozilla/5.0 (X11; U; Linux armv7l like Android; en-us) AppleWebKit/531.2+ (KHTML, like Gecko) Version/5.0 Safari/533.2+ Kindle/3.0+
506
  *
507
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
508
+ *
509
  * @return boolean true if the browser is Kindle monochrome Native browser otherwise false
510
  */
511
  public static function is_kindle_touch() {
516
 
517
  /**
518
  * Detect if user agent is the WordPress.com Windows 8 app (used ONLY on the custom oauth stylesheet)
519
+ *
520
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
521
  */
522
  public static function is_windows8_auth() {
523
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_windows8_auth from the `automattic/jetpack-device-detection` package' );
526
 
527
  /**
528
  * Detect if user agent is the WordPress.com Windows 8 app.
529
+ *
530
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
531
  */
532
  public static function is_wordpress_for_win8() {
533
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_wordpress_for_win8 from the `automattic/jetpack-device-detection` package' );
536
 
537
  /**
538
  * Detect if user agent is the WordPress.com Desktop app.
539
+ *
540
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
541
  */
542
  public static function is_wordpress_desktop_app() {
543
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_wordpress_desktop_app from the `automattic/jetpack-device-detection` package' );
548
  * The is_blackberry_tablet() method can be used to check the User Agent for a RIM blackberry tablet.
549
  * The user agent of the BlackBerry® Tablet OS follows a format similar to the following:
550
  * Mozilla/5.0 (PlayBook; U; RIM Tablet OS 1.0.0; en-US) AppleWebKit/534.8+ (KHTML, like Gecko) Version/0.0.1 Safari/534.8+
551
+ *
552
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
553
  */
554
  public static function is_blackberry_tablet() {
555
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_blackberry_tablet from the `automattic/jetpack-device-detection` package' );
559
  /**
560
  * The is_blackbeberry() method can be used to check the User Agent for a blackberry device.
561
  * Note that opera mini on BB matches this rule.
562
+ *
563
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
564
  */
565
  public static function is_blackbeberry() {
566
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_blackbeberry from the `automattic/jetpack-device-detection` package' );
569
 
570
  /**
571
  * The is_blackberry_10() method can be used to check the User Agent for a BlackBerry 10 device.
572
+ *
573
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
574
  */
575
  public static function is_blackberry_10() {
576
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_blackberry_10 from the `automattic/jetpack-device-detection` package' );
590
  * - blackberry-4.6
591
  * - blackberry-4.5
592
  *
593
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
594
+ *
595
+ * @return string Version of the BB OS. If version is not found, get_blackbeberry_OS_version will return boolean false.
596
  */
597
  public static function get_blackbeberry_OS_version() {
598
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::get_blackbeberry_OS_version from the `automattic/jetpack-device-detection` package' );
609
  * - blackberry-4.7
610
  * - blackberry-4.6
611
  *
612
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
613
+ *
614
+ * @return string Type of the BB browser. If browser's version is not found, detect_blackbeberry_browser_version will return boolean false.
615
  */
616
  public static function detect_blackberry_browser_version() {
617
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::detect_blackberry_browser_version from the `automattic/jetpack-device-detection` package' );
621
  /**
622
  * Checks if a visitor is coming from one of the WordPress mobile apps.
623
  *
624
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
625
+ *
626
  * @return bool
627
  */
628
  public static function is_mobile_app() {
635
  *
636
  * Example: Mozilla/5.0 (Nintendo 3DS; U; ; en) Version/1.7498.US
637
  * can differ in language, version and region
638
+ *
639
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
640
  */
641
  public static function is_Nintendo_3DS() {
642
  _deprecated_function( __METHOD__, 'Jetpack 8.7', '\Automattic\Jetpack\Device_Detection\User_Agent_Info::is_Nintendo_3DS from the `automattic/jetpack-device-detection` package' );
646
  /**
647
  * Was the current request made by a known bot?
648
  *
649
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
650
+ *
651
  * @return boolean
652
  */
653
  public static function is_bot() {
661
  *
662
  * @param string $ua A user-agent string.
663
  *
664
+ * @deprecated 8.7.0 Use Automattic\Jetpack\Device_Detection\User_Agent_Info
665
+ *
666
  * @return boolean
667
  */
668
  public static function is_bot_user_agent( $ua = null ) {
jetpack.php CHANGED
@@ -4,7 +4,7 @@
4
  * Plugin URI: https://jetpack.com
5
  * Description: Bring the power of the WordPress.com cloud to your self-hosted WordPress. Jetpack enables you to connect your blog to a WordPress.com account to use the powerful features normally only available to WordPress.com users.
6
  * Author: Automattic
7
- * Version: 8.7
8
  * Author URI: https://jetpack.com
9
  * License: GPL2+
10
  * Text Domain: jetpack
@@ -17,7 +17,7 @@
17
 
18
  define( 'JETPACK__MINIMUM_WP_VERSION', '5.3' );
19
  define( 'JETPACK__MINIMUM_PHP_VERSION', '5.6' );
20
- define( 'JETPACK__VERSION', '8.7' );
21
  define( 'JETPACK_MASTER_USER', true );
22
  define( 'JETPACK__API_VERSION', 1 );
23
  define( 'JETPACK__PLUGIN_DIR', plugin_dir_path( __FILE__ ) );
4
  * Plugin URI: https://jetpack.com
5
  * Description: Bring the power of the WordPress.com cloud to your self-hosted WordPress. Jetpack enables you to connect your blog to a WordPress.com account to use the powerful features normally only available to WordPress.com users.
6
  * Author: Automattic
7
+ * Version: 8.7.0.1
8
  * Author URI: https://jetpack.com
9
  * License: GPL2+
10
  * Text Domain: jetpack
17
 
18
  define( 'JETPACK__MINIMUM_WP_VERSION', '5.3' );
19
  define( 'JETPACK__MINIMUM_PHP_VERSION', '5.6' );
20
+ define( 'JETPACK__VERSION', '8.7.0.1' );
21
  define( 'JETPACK_MASTER_USER', true );
22
  define( 'JETPACK__API_VERSION', 1 );
23
  define( 'JETPACK__PLUGIN_DIR', plugin_dir_path( __FILE__ ) );
vendor/class-plugins-handler.php CHANGED
@@ -76,7 +76,7 @@ class Plugins_Handler {
76
  * @return bool
77
  */
78
  public function is_directory_plugin( $plugin ) {
79
- return false !== strpos( $plugin, '/', 1 );
80
  }
81
 
82
  /**
76
  * @return bool
77
  */
78
  public function is_directory_plugin( $plugin ) {
79
+ return strlen( $plugin ) > 1 && false !== strpos( $plugin, '/', 1 );
80
  }
81
 
82
  /**