original_string: public function makeWidget($class, $widgetConfig = [])
      {
          $controller = property_exists($this, 'controller') && $this->controller
              ? $this->controller
              : $this;
  
          if (!class_exists($class)) {
              throw new SystemException(Lang::get('backend::lang.widget.not_registered', [
                  'name' => $class
              ]));
          }
  
          return new $class($controller, $widgetConfig);
      }
code: public function makeWidget($class, $widgetConfig = [])
      {
          $controller = property_exists($this, 'controller') && $this->controller
              ? $this->controller
              : $this;
  
          if (!class_exists($class)) {
              throw new SystemException(Lang::get('backend::lang.widget.not_registered', [
                  'name' => $class
              ]));
          }
  
          return new $class($controller, $widgetConfig);
      }
code_tokens: public function makeWidget ( $ class , $ widgetConfig = [ ] ) { $ controller = property_exists ( $ this , 'controller' ) && $ this -> controller ? $ this -> controller : $ this ; if ( ! class_exists ( $ class ) ) { throw new SystemException ( Lang :: get ( 'backend::lang.widget.not_registered' , [ 'name' => $ class ] ) ) ; } return new $ class ( $ controller , $ widgetConfig ) ; }
docstring: Makes a widget object with the supplied configuration file.
  @param string $class Widget class name
  @param array $widgetConfig An array of config.
  @return \Backend\Classes\WidgetBase The widget object
docstring_tokens: Makes a widget object with the supplied configuration file .