Skip to content

Commit

Permalink
updating the .env.example to make sure it doesn't have demo mode on b…
Browse files Browse the repository at this point in the history
…y default.
  • Loading branch information
tnylea committed Oct 4, 2024
1 parent 0587e4c commit 5560735
Showing 1 changed file with 15 additions and 13 deletions.
28 changes: 15 additions & 13 deletions wave/src/WaveServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -269,22 +269,24 @@ protected function setDefaultThemeColors(){
if(config('wave.demo')){
$theme = $this->getActiveTheme();

if(Cookie::get('theme')){
$theme_cookied = \DevDojo\Themes\Models\Theme::where('folder', '=', Cookie::get('theme'))->first();
if(isset($theme_cookied->id)){
$theme = $theme_cookied;
if(isset($theme->id)){
if(Cookie::get('theme')){
$theme_cookied = \DevDojo\Themes\Models\Theme::where('folder', '=', Cookie::get('theme'))->first();
if(isset($theme_cookied->id)){
$theme = $theme_cookied;
}
}
}

$default_theme_color = match($theme->folder){
'anchor' => '#000000',
'blank' => '#090909',
'cove' => '#0069ff',
'drift' => '#000000',
'fusion' => '#0069ff'
};
$default_theme_color = match($theme->folder){
'anchor' => '#000000',
'blank' => '#090909',
'cove' => '#0069ff',
'drift' => '#000000',
'fusion' => '#0069ff'
};

Config::set('wave.primary_color', $default_theme_color);
Config::set('wave.primary_color', $default_theme_color);
}
}
}

Expand Down

0 comments on commit 5560735

Please sign in to comment.