public function renderView($template)
    {
        if (array_key_exists($template, $this->views)) {
            echo $this->views[$template]->render();
            return false;
        }

        return $template;
    }
public function renderView($template)
    {
        if (array_key_exists($template, $this->views)) {
            echo $this->views[$template]->render();
            return false;
        }

        return $template;
    }
public function renderView ( $ template ) { if ( array_key_exists ( $ template , $ this -> views ) ) { echo $ this -> views [ $ template ] -> render ( ) ; return false ; } return $ template ; }
Called by the WordPress include_template filter, so we can
intercept it and render our registered View object instead.

This is not a great solution because WordPress filters should not
cause side effects, but in this case, on render is the only time
this filter should be called. Still, we will acknowledge that
it is a hack

@param  string $template template file
@return string           template file, return false if rendering
Called by the WordPress include_template filter so we can intercept it and render our registered View object instead .