From 455f31aa24ee448db66ed25f3b96bf6ecc627b25 Mon Sep 17 00:00:00 2001 From: "chencongzhi520@gmail.com" Date: Mon, 20 May 2013 05:36:11 +0000 Subject: [PATCH] * fix bug: adjust the code the delete a user's priviledge when edit a user profile. --- module/user/model.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/module/user/model.php b/module/user/model.php index 517864814e..36c34ed4db 100644 --- a/module/user/model.php +++ b/module/user/model.php @@ -342,9 +342,9 @@ class userModel extends model } } - $this->dao->delete()->from(TABLE_USERGROUP)->where('account')->eq($oldUser->account)->exec(); if($this->post->groups) { + $this->dao->delete()->from(TABLE_USERGROUP)->where('account')->eq($oldUser->account)->exec(); foreach($this->post->groups as $groupID) { $data->account = $this->post->account;