Skip to content

Commit

Permalink
Merge pull request #37 from yourjhay/develop
Browse files Browse the repository at this point in the history
Remove request on view class
  • Loading branch information
yourjhay authored Nov 18, 2023
2 parents e18fdd4 + b276970 commit c259640
Showing 1 changed file with 0 additions and 7 deletions.
7 changes: 0 additions & 7 deletions src/Simple/View.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,6 @@

class View
{
private Request $request;

public function __construct()
{
$this->request = new Request;
}

/**
* Render A view
Expand Down Expand Up @@ -95,7 +89,6 @@ public function render(string $template, array $args = []): string
$twig->addExtension(new \Twig\Extension\DebugExtension());
$twig->addGlobal('flushable', Session::getFlushable());
$twig->addGlobal('baseurl', $url);
$twig->addGlobal('request', $this->request);
$twig->addGlobal('old', Session::get('_old'));
$twig->addGlobal('_get', $_GET);
if (Session::get('user')) {
Expand Down

0 comments on commit c259640

Please sign in to comment.