From 6868c239a567ab145aa79f968486903171c4692d Mon Sep 17 00:00:00 2001 From: hackerESQ Date: Sat, 26 Oct 2024 11:18:08 -0500 Subject: [PATCH] fix:wrong key used for daily change time of day config --- app/Models/Portfolio.php | 2 +- routes/console.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/Models/Portfolio.php b/app/Models/Portfolio.php index e91d273..8f8a615 100644 --- a/app/Models/Portfolio.php +++ b/app/Models/Portfolio.php @@ -143,7 +143,7 @@ class Portfolio extends Model $holdings->each(function($holding) use (&$total_performance, $dividends) { - $period = CarbonPeriod::create($holding->first_transaction_date, now()->isBefore(Carbon::parse(config('daily_change_time_of_day'))) ? now()->subDay() : now())->filter('isWeekday'); + $period = CarbonPeriod::create($holding->first_transaction_date, now()->isBefore(Carbon::parse(config('investbrain.daily_change_time_of_day'))) ? now()->subDay() : now())->filter('isWeekday'); $holding->setRelation('dividends', $dividends->where('symbol', $holding->symbol)); diff --git a/routes/console.php b/routes/console.php index e0e489f..d8280f9 100644 --- a/routes/console.php +++ b/routes/console.php @@ -14,7 +14,7 @@ Schedule::command(RefreshMarketData::class)->everyMinute()->weekdays(); * * This scheduled job records daily changes to your portfolios every weekday */ -Schedule::command(CaptureDailyChange::class)->dailyAt(config('daily_change_time_of_day'))->weekdays(); +Schedule::command(CaptureDailyChange::class)->dailyAt(config('investbrain.daily_change_time_of_day'))->weekdays(); /** *