File tree Expand file tree Collapse file tree 2 files changed +2
-5
lines changed Expand file tree Collapse file tree 2 files changed +2
-5
lines changed Original file line number Diff line number Diff line change @@ -648,9 +648,6 @@ public function __toString(): string
648648 return $ this ->getRenderer ()->render ($ this );
649649
650650 } catch (\Throwable $ e ) {
651- } catch (\Exception $ e ) {
652- }
653- if (isset ($ e )) {
654651 if (func_num_args ()) {
655652 throw $ e ;
656653 }
Original file line number Diff line number Diff line change @@ -179,7 +179,7 @@ public function addFilter($filter)
179179 $ this ->rules [] = $ rule = new Rule ;
180180 $ rule ->control = $ this ->control ;
181181 $ rule ->validator = function (IControl $ control ) use ($ filter ) {
182- $ control ->setValue (call_user_func ( $ filter, $ control ->getValue ()));
182+ $ control ->setValue ($ filter( $ control ->getValue ()));
183183 return TRUE ;
184184 };
185185 return $ this ;
@@ -287,7 +287,7 @@ public static function validateRule(Rule $rule)
287287 $ val = $ val instanceof IControl ? $ val ->getValue () : $ val ;
288288 }
289289 return $ rule ->isNegative
290- xor call_user_func ( self ::getCallback ($ rule ), $ rule ->control , is_array ($ rule ->arg ) ? $ args : $ args [0 ]);
290+ xor self ::getCallback ($ rule )( $ rule ->control , is_array ($ rule ->arg ) ? $ args : $ args [0 ]);
291291 }
292292
293293
You can’t perform that action at this time.
0 commit comments