* fix bug for batch create user.

This commit is contained in:
wangyidong
2019-08-26 10:42:02 +08:00
parent 970b2bb9d9
commit 240d306680
+1 -1
View File
@@ -283,7 +283,7 @@ class userModel extends model
/* Check weak and common weak password. */
if(isset($this->config->safe->mode) and $this->computePasswordStrength($users->password[$i]) < $this->config->safe->mode) die(js::error(sprintf($this->lang->user->error->weakPassword, $i + 1)));
if(!empty($this->config->safe->changeWeak) and strpos(",{$this->config->safe->weak},", ",{$this->post->password1},") !== false) die(js::error(sprintf($this->lang->user->error->dangerPassword, $i + 1, $this->config->safe->weak)));
if(!empty($this->config->safe->changeWeak) and strpos(",{$this->config->safe->weak},", ",{$users->password[$i]},") !== false) die(js::error(sprintf($this->lang->user->error->dangerPassword, $i + 1, $this->config->safe->weak)));
$data[$i] = new stdclass();
$data[$i]->dept = $users->dept[$i] == 'ditto' ? (isset($prev['dept']) ? $prev['dept'] : 0) : $users->dept[$i];