fix carbon addDays

This commit is contained in:
xiaomlove
2025-05-02 21:21:37 +07:00
parent 6a3ed230df
commit 8f4a6cf50c
5 changed files with 9 additions and 9 deletions
+1 -1
View File
@@ -104,7 +104,7 @@ class ExamUser extends NexusModel
$duration = $exam->duration;
if ($duration > 0) {
do_log(sprintf('examUser: %s, end from self created_at + exam(%s) created_at: %s + %s days', $this->id, $exam->id, $this->getRawOriginal('created_at'), $duration));
return $this->created_at->addDays($duration)->toDateTimeString();
return $this->created_at->addDays((int)$duration)->toDateTimeString();
}
return null;
}