Skip to content

Commit

Permalink
corrige configuração de rotas via conf-base dos temas
Browse files Browse the repository at this point in the history
  • Loading branch information
rafaelchavesfreitas committed Dec 9, 2024
1 parent d2408c5 commit f33d6f4
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/core/Theme.php
Original file line number Diff line number Diff line change
Expand Up @@ -120,11 +120,12 @@ public function __construct(AssetManager $asset_manager) {
'timezone' => date_default_timezone_get(),
'currency' => $app->config['app.currency']
];
$this->jsObject['routes'] = $app->config['routes'];


$app->hook('app.init:after', function(){
$this->view->jsObject['userId'] = $this->user->is('guest') ? null : $this->user->id;
$this->view->jsObject['user'] = $this->user;
$this->view->jsObject['routes'] = $this->config['routes'];
});

$app->hook('app.register', function() use($app){
Expand Down

0 comments on commit f33d6f4

Please sign in to comment.