File tree Expand file tree Collapse file tree 1 file changed +15
-24
lines changed
Expand file tree Collapse file tree 1 file changed +15
-24
lines changed Original file line number Diff line number Diff line change @@ -96,30 +96,21 @@ private function processMethod(array $method): Collection
9696
9797 private function isBlacklisted (string $ methodName ): bool
9898 {
99- if ($ methodName === 'only ' ) {
100- return true ;
101- }
102-
103- if ($ methodName === 'input ' ) {
104- return true ;
105- }
106-
107- if ($ methodName === 'get ' ) {
108- return true ;
109- }
110-
111- if ($ methodName === 'string ' ) {
112- return true ;
113- }
114-
115- if ($ methodName === 'integer ' ) {
116- return true ;
117- }
118-
119- if ($ methodName === 'boolean ' ) {
120- return true ;
121- }
99+ $ blacklistedMethodNames = [
100+ 'collect ' ,
101+ 'all ' ,
102+ 'only ' ,
103+ 'except ' ,
104+ 'input ' ,
105+ 'get ' ,
106+ 'keys ' ,
107+ 'string ' ,
108+ 'str ' ,
109+ 'integer ' ,
110+ 'float ' ,
111+ 'boolean ' ,
112+ ];
122113
123- return false ;
114+ return in_array ( $ methodName , $ blacklistedMethodNames , strict: true ) ;
124115 }
125116}
You can’t perform that action at this time.
0 commit comments