File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -128,7 +128,7 @@ protected function parseComment(string $comment): void
128
128
else
129
129
{
130
130
// This block is tagged
131
- $ tag = \substr (self ::strTag ($ body ), 1 );
131
+ $ tag = ( string ) \substr (self ::strTag ($ body ), 1 );
132
132
$ body = \ltrim ((string )\substr ($ body , \strlen ($ tag ) + 2 ));
133
133
134
134
if (isset (self ::$ vectors [$ tag ])) {
@@ -226,14 +226,14 @@ public static function isTagged(string $str): bool
226
226
*
227
227
* @param string $str
228
228
*
229
- * @return string|null
229
+ * @return string
230
230
*/
231
- public static function strTag (string $ str ): ? string
231
+ public static function strTag (string $ str ): string
232
232
{
233
233
if (\preg_match ('/^@[a-z0-9_]+/ ' , $ str , $ matches )) {
234
- return $ matches [0 ];
234
+ return ( string ) $ matches [0 ];
235
235
}
236
236
237
- return null ;
237
+ return '' ;
238
238
}
239
239
}
You can’t perform that action at this time.
0 commit comments