fix hr display error when not download completed

This commit is contained in:
xiaomlove
2023-09-21 03:23:40 +08:00
parent 36aa10f64f
commit ab517bf412
4 changed files with 9 additions and 5 deletions

View File

@@ -236,7 +236,7 @@ class HitAndRunRepository extends BaseRepository
'added' => Carbon::now()->toDateTimeString(),
'subject' => nexus_trans('hr.reached_message_subject', ['hit_and_run_id' => $hitAndRun->id], $hitAndRun->user->locale),
'msg' => nexus_trans('hr.reached_message_content', [
'completed_at' => $hitAndRun->snatch->completedat->toDateTimeString(),
'completed_at' => format_datetime($hitAndRun->snatch->completedat),
'torrent_id' => $hitAndRun->torrent_id,
'torrent_name' => $hitAndRun->torrent->name,
], $hitAndRun->user->locale),
@@ -335,7 +335,7 @@ class HitAndRunRepository extends BaseRepository
'added' => Carbon::now()->toDateTimeString(),
'subject' => nexus_trans('hr.unreached_message_subject', ['hit_and_run_id' => $hitAndRun->id], $hitAndRun->user->locale),
'msg' => nexus_trans('hr.unreached_message_content', [
'completed_at' => $hitAndRun->snatch->completedat->toDateTimeString(),
'completed_at' => format_datetime($hitAndRun->snatch->completedat),
'torrent_id' => $hitAndRun->torrent_id,
'torrent_name' => $hitAndRun->torrent->name,
], $hitAndRun->user->locale),