Added Notifications
This commit is contained in:
1 parent
a6812ad95c
commit
0f12250644
2 files changed
+6
-1
No files matched your search
@@ -28,7 +28,9 @@ class FlightFeedUpdate extends Command
|
||||
*/
|
||||
private function logFlightActions(string $type, Collection $flights): void
|
||||
{
|
||||
|
||||
foreach ($flights as $flight) {
|
||||
|
||||
UserAction::create([
|
||||
'user_id' => $flight->user_id,
|
||||
'type' => $type,
|
||||
@@ -36,6 +38,10 @@ class FlightFeedUpdate extends Command
|
||||
'flight' => $flight->snapshot($flight->id),
|
||||
]
|
||||
]);
|
||||
|
||||
if($type === 'flight_departing'){
|
||||
$flight->user->calculateAchievements();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user