From 70e5b9c38bf02fd9f7fe7eb9986f6519b3c04304 Mon Sep 17 00:00:00 2001 From: vlakoff Date: Wed, 7 Jan 2015 01:24:40 +0100 Subject: [PATCH] Remove some useless (and erroneous) regex capturing groups --- src/Stringy.php | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/Stringy.php b/src/Stringy.php index a8bb803..90f3da7 100644 --- a/src/Stringy.php +++ b/src/Stringy.php @@ -1247,7 +1247,7 @@ class Stringy implements \Countable, \IteratorAggregate, \ArrayAccess */ public function isAlpha() { - return $this->matchesPattern('^([[:alpha:]])*$'); + return $this->matchesPattern('^[[:alpha:]]*$'); } /** @@ -1258,7 +1258,7 @@ class Stringy implements \Countable, \IteratorAggregate, \ArrayAccess */ public function isAlphanumeric() { - return $this->matchesPattern('^([[:alnum:]])*$'); + return $this->matchesPattern('^[[:alnum:]]*$'); } /** @@ -1269,7 +1269,7 @@ class Stringy implements \Countable, \IteratorAggregate, \ArrayAccess */ public function isHexadecimal() { - return $this->matchesPattern('^([[:xdigit:]])*$'); + return $this->matchesPattern('^[[:xdigit:]]*$'); } /** @@ -1280,7 +1280,7 @@ class Stringy implements \Countable, \IteratorAggregate, \ArrayAccess */ public function isBlank() { - return $this->matchesPattern('^([[:space:]])*$'); + return $this->matchesPattern('^[[:space:]]*$'); } /** @@ -1303,7 +1303,7 @@ class Stringy implements \Countable, \IteratorAggregate, \ArrayAccess */ public function isLowerCase() { - return $this->matchesPattern('^([[:lower:]])*$'); + return $this->matchesPattern('^[[:lower:]]*$'); } /** @@ -1314,7 +1314,7 @@ class Stringy implements \Countable, \IteratorAggregate, \ArrayAccess */ public function isUpperCase() { - return $this->matchesPattern('^([[:upper:]])*$'); + return $this->matchesPattern('^[[:upper:]]*$'); } /**