From 4c43016b1e2a453f4da2657c49d8e0aeae9603da Mon Sep 17 00:00:00 2001 From: wanghousheng Date: Thu, 21 Mar 2024 21:57:49 +0800 Subject: [PATCH] 1 --- app/store/controller/User.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/store/controller/User.php b/app/store/controller/User.php index 25f45023..9ff14343 100644 --- a/app/store/controller/User.php +++ b/app/store/controller/User.php @@ -12,8 +12,8 @@ declare (strict_types=1); namespace app\store\controller; -use think\response\Json; use app\store\model\User as UserModel; +use think\response\Json; /** * 用户管理 @@ -60,7 +60,7 @@ class User extends Controller { // 用户详情 $model = UserModel::detail($userId); - if ($model->recharge($target, $this->postForm())) { + if ((new UserModel())->recharge($target, $this->postForm())) { return $this->renderSuccess('操作成功'); } return $this->renderError($model->getError() ?: '操作失败');