attempt to fix again
This commit is contained in:
parent
fe821c3e8b
commit
14f80ab573
|
|
@ -92,13 +92,14 @@ class UserController extends Controller
|
|||
$user = Auth::user();
|
||||
if ($user->canSign()) {
|
||||
$acquiredScore = $user->sign();
|
||||
$gap = option('sign_gap_time');
|
||||
|
||||
return json([
|
||||
'errno' => 0,
|
||||
'msg' => trans('user.sign-success', ['score' => $acquiredScore]),
|
||||
'score' => $user->getScore(),
|
||||
'storage' => $this->calculatePercentageUsed($user->getStorageUsed(), option('score_per_storage')),
|
||||
'remaining_time' => $this->getUserSignRemainingTimeWithPrecision($user)
|
||||
'remaining_time' => $gap > 1 ? round($gap) : $gap
|
||||
]);
|
||||
} else {
|
||||
$remaining_time = $this->getUserSignRemainingTimeWithPrecision();
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user