diff --git a/src/Illuminate/Support/Stringable.php b/src/Illuminate/Support/Stringable.php index c89abb01e41c..144cbb8c5537 100644 --- a/src/Illuminate/Support/Stringable.php +++ b/src/Illuminate/Support/Stringable.php @@ -1281,11 +1281,12 @@ public function toString() /** * Get the underlying string value as an integer. * + * @param int $base * @return int */ - public function toInteger() + public function toInteger($base = 10) { - return intval($this->value); + return intval($this->value, $base); } /**