fix for test

This commit is contained in:
Pig Fang 2018-07-12 10:52:58 +08:00
parent 023a48aa8a
commit 2cea484f50

View File

@ -69,6 +69,11 @@ class UserController extends Controller
*/
public function sign()
{
// Hacking for testing
if (config('app.env') == 'testing') {
$this->user = User::find($this->user->uid);
}
if ($this->user->canSign()) {
$acquiredScore = $this->user->sign();