mirror of
https://github.com/danielstjules/Stringy.git
synced 2025-08-12 16:24:00 +02:00
Remove some useless (and erroneous) regex capturing groups
This commit is contained in:
@@ -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:]]*$');
|
||||
}
|
||||
|
||||
/**
|
||||
|
Reference in New Issue
Block a user