summaryrefslogtreecommitdiffstats
path: root/apps/dav/lib/Connector/Sabre/BlockLegacyClientPlugin.php
diff options
context:
space:
mode:
Diffstat (limited to 'apps/dav/lib/Connector/Sabre/BlockLegacyClientPlugin.php')
-rw-r--r--apps/dav/lib/Connector/Sabre/BlockLegacyClientPlugin.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/apps/dav/lib/Connector/Sabre/BlockLegacyClientPlugin.php b/apps/dav/lib/Connector/Sabre/BlockLegacyClientPlugin.php
index 1ddebe06ee1..b64feb22f48 100644
--- a/apps/dav/lib/Connector/Sabre/BlockLegacyClientPlugin.php
+++ b/apps/dav/lib/Connector/Sabre/BlockLegacyClientPlugin.php
@@ -65,7 +65,7 @@ class BlockLegacyClientPlugin extends ServerPlugin {
*/
public function beforeHandler(RequestInterface $request) {
$userAgent = $request->getHeader('User-Agent');
- if($userAgent === null) {
+ if ($userAgent === null) {
return;
}
@@ -74,7 +74,7 @@ class BlockLegacyClientPlugin extends ServerPlugin {
// Match on the mirall version which is in scheme "Mozilla/5.0 (%1) mirall/%2" or
// "mirall/%1" for older releases
preg_match("/(?:mirall\\/)([\d.]+)/i", $userAgent, $versionMatches);
- if(isset($versionMatches[1]) &&
+ if (isset($versionMatches[1]) &&
version_compare($versionMatches[1], $minimumSupportedDesktopVersion) === -1) {
throw new \Sabre\DAV\Exception\Forbidden('Unsupported client version.');
}