Datatype fix
This commit is contained in:
parent
86728cb214
commit
d558e2ba99
|
|
@ -111,7 +111,7 @@ class HashTable
|
||||||
*
|
*
|
||||||
* @param string $hashCode
|
* @param string $hashCode
|
||||||
*
|
*
|
||||||
* @return int Index
|
* @return false|int Index
|
||||||
*/
|
*/
|
||||||
public function getIndexForHashCode($hashCode)
|
public function getIndexForHashCode($hashCode)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -14,7 +14,7 @@ class Size
|
||||||
|
|
||||||
public function __construct(string $size)
|
public function __construct(string $size)
|
||||||
{
|
{
|
||||||
$this->valid = preg_match(self::REGEXP_SIZE_VALIDATION, $size, $matches);
|
$this->valid = (bool) preg_match(self::REGEXP_SIZE_VALIDATION, $size, $matches);
|
||||||
if ($this->valid) {
|
if ($this->valid) {
|
||||||
$this->size = $matches['size'];
|
$this->size = $matches['size'];
|
||||||
$this->unit = $matches['unit'] ?? 'pt';
|
$this->unit = $matches['unit'] ?? 'pt';
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue