From 9e1d9d017e7893dc404f159a6c118777f06d126b Mon Sep 17 00:00:00 2001 From: Matthew Wire Date: Wed, 28 Mar 2018 10:36:57 +0100 Subject: [PATCH] Fix function name typo --- CRM/Utils/Rule.php | 2 +- CRM/Utils/Type.php | 2 +- tests/phpunit/CRM/Utils/RuleTest.php | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/CRM/Utils/Rule.php b/CRM/Utils/Rule.php index ada29634f1..e053e9e81c 100644 --- a/CRM/Utils/Rule.php +++ b/CRM/Utils/Rule.php @@ -935,7 +935,7 @@ class CRM_Utils_Rule { * @param string $key Extension Key to check * @return bool */ - public static function checkExtesnionKeyIsValid($key = NULL) { + public static function checkExtensionKeyIsValid($key = NULL) { if (!empty($key) && !preg_match('/^[0-9a-zA-Z._-]+$/', $key)) { return FALSE; } diff --git a/CRM/Utils/Type.php b/CRM/Utils/Type.php index d96a0c4a13..1c99a7e06a 100644 --- a/CRM/Utils/Type.php +++ b/CRM/Utils/Type.php @@ -526,7 +526,7 @@ class CRM_Utils_Type { break; case 'ExtensionKey': - if (CRM_Utils_Rule::checkExtesnionKeyIsValid($data)) { + if (CRM_Utils_Rule::checkExtensionKeyIsValid($data)) { return $data; } break; diff --git a/tests/phpunit/CRM/Utils/RuleTest.php b/tests/phpunit/CRM/Utils/RuleTest.php index 9db05dbaa3..36e91e59b7 100644 --- a/tests/phpunit/CRM/Utils/RuleTest.php +++ b/tests/phpunit/CRM/Utils/RuleTest.php @@ -129,7 +129,7 @@ class CRM_Utils_RuleTest extends CiviUnitTestCase { * @dataProvider extenionKeyTests */ public function testExtenionKeyValid($key, $expectedResult) { - $this->assertEquals($expectedResult, CRM_Utils_Rule::checkExtesnionKeyIsValid($key)); + $this->assertEquals($expectedResult, CRM_Utils_Rule::checkExtensionKeyIsValid($key)); } } -- 2.25.1