_params['layout']) ? $this->_params['layout'] : false; # Create a template so we can call render_inline; $this->_template = new ActionView\Template(['inline' => $this->_params['code']], ['layout' => $layout]); $this->_template->setLocals(\Rails::application()->controller()->vars()); $this->_template->renderContent(); } public function _print_view() { return $this->_template->content(); } }