File tree Expand file tree Collapse file tree 4 files changed +4
-4
lines changed Expand file tree Collapse file tree 4 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -101,7 +101,7 @@ public static function from($from)
101
101
102
102
public function __construct ($ name = NULL , PhpNamespace $ namespace = NULL )
103
103
{
104
- $ this ->setName ($ name );
104
+ $ this ->setName (( string ) $ name );
105
105
$ this ->namespace = $ namespace ;
106
106
}
107
107
Original file line number Diff line number Diff line change @@ -285,7 +285,7 @@ public function setVisibility($val)
285
285
286
286
287
287
/**
288
- * @return string
288
+ * @return string|NULL
289
289
*/
290
290
public function getVisibility ()
291
291
{
Original file line number Diff line number Diff line change @@ -60,7 +60,7 @@ public static function from(\ReflectionParameter $from)
60
60
61
61
$ namespace = $ from ->getDeclaringClass () ? $ from ->getDeclaringClass ()->getNamespaceName () : NULL ;
62
62
$ namespace = $ namespace ? "\\$ namespace \\" : '\\' ;
63
- if (Nette \Utils \Strings::startsWith ($ param ->typeHint , $ namespace )) {
63
+ if ($ param -> typeHint !== NULL && Nette \Utils \Strings::startsWith ($ param ->typeHint , $ namespace )) {
64
64
$ param ->typeHint = substr ($ param ->typeHint , strlen ($ namespace ));
65
65
}
66
66
return $ param ;
Original file line number Diff line number Diff line change @@ -37,7 +37,7 @@ class PhpNamespace extends Object
37
37
38
38
public function __construct ($ name = NULL )
39
39
{
40
- $ this ->setName ($ name );
40
+ $ this ->setName (( string ) $ name );
41
41
}
42
42
43
43
You can’t perform that action at this time.
0 commit comments