mirror of
https://github.com/MrUnknownDE/panel.git
synced 2026-04-19 14:53:45 +02:00
Fix retry after header
This commit is contained in:
@@ -114,7 +114,7 @@ class InitiateBackupService
|
|||||||
$previous = $this->repository->getBackupsGeneratedDuringTimespan($server->id, $period);
|
$previous = $this->repository->getBackupsGeneratedDuringTimespan($server->id, $period);
|
||||||
if ($previous->count() >= $limit) {
|
if ($previous->count() >= $limit) {
|
||||||
throw new TooManyRequestsHttpException(
|
throw new TooManyRequestsHttpException(
|
||||||
CarbonImmutable::now()->diffInSeconds($previous->last()->created_at->addMinutes(10)),
|
CarbonImmutable::now()->diffInSeconds($previous->last()->created_at->addSeconds($period)),
|
||||||
sprintf('Only %d backups may be generated within a %d second span of time.', $limit, $period)
|
sprintf('Only %d backups may be generated within a %d second span of time.', $limit, $period)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user