Skip to content

Commit dfb59bc

Browse files
committed
return false'
1 parent 90635f9 commit dfb59bc

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/Illuminate/Support/Str.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -221,14 +221,14 @@ public static function camel($value)
221221
*
222222
* @param string $subject
223223
* @param int $index
224-
* @return string|null
224+
* @return string|false
225225
*/
226226
public static function charAt($subject, $index)
227227
{
228228
$length = mb_strlen($subject);
229229

230230
if ($index < 0 ? $index < -$length : $index > $length - 1) {
231-
return null;
231+
return false;
232232
}
233233

234234
return mb_substr($subject, $index, 1);

src/Illuminate/Support/Stringable.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ public function basename($suffix = '')
103103
* Get the character at the specified index.
104104
*
105105
* @param int $index
106-
* @return string|null
106+
* @return string|false
107107
*/
108108
public function charAt($index)
109109
{

0 commit comments

Comments
 (0)