param; $user = $this->sessionUser->user(); if ($user instanceof null) { throw new LogicException(); } if ($user->shop_id === null) { throw new LogicException(); } $deposit = $this->logic->charge($user->shop_id, $param->amount); $res = [ "shop_id" => $deposit->shop_id, "deposit" => $deposit->deposit, ]; return $this->successResponse($res); } }