router update
This commit is contained in:
		@@ -60,16 +60,18 @@ class Router{
 | 
				
			|||||||
      }
 | 
					      }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
      if($this->function !== NULL){
 | 
					      if($this->function !== NULL){
 | 
				
			||||||
         if(strpos($this->function, '@') !== false){
 | 
								if(is_string($this->function)){
 | 
				
			||||||
            list($class, $function) = explode('@', $this->function);
 | 
									if(strpos($this->function, '@') !== false){
 | 
				
			||||||
            $method = new ReflectionMethod($class, $function);
 | 
										list($class, $function) = explode('@', $this->function);
 | 
				
			||||||
            if($method->isStatic()){
 | 
										$method = new ReflectionMethod($class, $function);
 | 
				
			||||||
               call_user_func_array([$class, $function], $this->params);
 | 
										if($method->isStatic()){
 | 
				
			||||||
            }else{
 | 
											call_user_func_array([$class, $function], $this->params);
 | 
				
			||||||
               call_user_func_array([new $class, $function], $this->params);
 | 
										}else{
 | 
				
			||||||
            }
 | 
											call_user_func_array([new $class, $function], $this->params);
 | 
				
			||||||
         }else if(class_exists($this->function)){
 | 
										}
 | 
				
			||||||
            new $this->function(...$this->params);
 | 
									}else if(class_exists($this->function)){
 | 
				
			||||||
 | 
										new $this->function(...$this->params);
 | 
				
			||||||
 | 
									}
 | 
				
			||||||
         }else if (is_callable($this->function)) {
 | 
					         }else if (is_callable($this->function)) {
 | 
				
			||||||
            call_user_func_array($this->function, $this->params);
 | 
					            call_user_func_array($this->function, $this->params);
 | 
				
			||||||
         }
 | 
					         }
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user