Skip to content

Commit

Permalink
Merge pull request #1370 from shikorism/develop
Browse files Browse the repository at this point in the history
Release 2024.12.2
  • Loading branch information
shibafu528 authored Dec 7, 2024
2 parents dd9ee82 + 25a26d4 commit 6955eb2
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
3 changes: 1 addition & 2 deletions app/User.php
Original file line number Diff line number Diff line change
Expand Up @@ -111,8 +111,7 @@ public function checkinSummary(): ?array
->orderByDesc('ejaculated_date')
->first();
if (!empty($latestEjaculation)) {
$currentSession = $latestEjaculation->ejaculated_date
->diffInSeconds(Carbon::now());
$currentSession = (int) $latestEjaculation->ejaculated_date->diffInSeconds(Carbon::now());
} else {
$currentSession = null;
}
Expand Down
2 changes: 1 addition & 1 deletion app/Utilities/ApplyProviderPolicyMiddleware.php
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ private function checkProviderPolicy(string $url, ?CarbonInterface $lastAccess)

// 連続アクセス制限
if ($lastAccess !== null) {
$elapsedSeconds = $lastAccess->diffInSeconds(now(), false);
$elapsedSeconds = (int) $lastAccess->diffInSeconds(now());
if ($elapsedSeconds < $contentProvider->access_interval_sec) {
if ($elapsedSeconds < 0) {
$wait = abs($elapsedSeconds) + $contentProvider->access_interval_sec;
Expand Down

0 comments on commit 6955eb2

Please sign in to comment.