From dadd2c91df0010844bfc507b83462cd4af0bef7a Mon Sep 17 00:00:00 2001 From: Andreas Elia Date: Fri, 29 Mar 2024 16:15:53 +0000 Subject: [PATCH] updates --- src/Agent.php | 23 ++++++++++++----------- 1 file changed, 12 insertions(+), 11 deletions(-) diff --git a/src/Agent.php b/src/Agent.php index 4d2d642..947066a 100644 --- a/src/Agent.php +++ b/src/Agent.php @@ -203,7 +203,8 @@ public function device($userAgent = null) static::getDesktopDevices(), static::getPhoneDevices(), static::getTabletDevices(), - static::getUtilities() + // TODO: this was removed, is there an alternative? what was it for? + // static::getUtilities() ); return $this->findDetectionRulesAgainstUA($rules, $userAgent); @@ -316,17 +317,17 @@ protected static function mergeRules(...$all) return $merged; } - public function __call(string $name, array $arguments) - { - // Make sure the name starts with 'is', otherwise - if (strpos($name, 'is') !== 0) { - throw new BadMethodCallException("No such method exists: $name"); - } + // public function __call(string $name, array $arguments) + // { + // // Make sure the name starts with 'is', otherwise + // if (strpos($name, 'is') !== 0) { + // throw new BadMethodCallException("No such method exists: $name"); + // } - // $this->setDetectionType(self::DETECTION_TYPE_EXTENDED); + // // $this->setDetectionType(self::DETECTION_TYPE_EXTENDED); - $key = substr($name, 2); + // $key = substr($name, 2); - return $this->matchUAAgainstKey($key); - } + // return $this->matchUAAgainstKey($key); + // } }