Skip to content

Commit 5bebbcb

Browse files
committed
Fixed: FS#776 - Client's limits do not apply for it's own client
1 parent cc99cf8 commit 5bebbcb

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

interface/web/client/reseller_edit.php

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -143,9 +143,8 @@ function onAfterInsert() {
143143

144144
$username = $app->db->quote($this->dataRecord["username"]);
145145
$password = $app->db->quote($this->dataRecord["password"]);
146-
$modules = ISPC_INTERFACE_MODULES_ENABLED;
147-
if($this->dataRecord["limit_client"] > 0) $modules .= ',client';
148-
$startmodule = 'mail';
146+
$modules = ISPC_INTERFACE_MODULES_ENABLED.',client';
147+
$startmodule = 'client';
149148
$usertheme = $app->db->quote($this->dataRecord["usertheme"]);
150149
$type = 'user';
151150
$active = 1;
@@ -195,8 +194,7 @@ function onAfterUpdate() {
195194

196195
// reseller status changed
197196
if(isset($this->dataRecord["limit_client"]) && $this->dataRecord["limit_client"] != $this->oldDataRecord["limit_client"]) {
198-
$modules = ISPC_INTERFACE_MODULES_ENABLED;
199-
if($this->dataRecord["limit_client"] > 0) $modules .= ',client';
197+
$modules = ISPC_INTERFACE_MODULES_ENABLED.',client';
200198
$modules = $app->db->quote($modules);
201199
$client_id = $this->id;
202200
$sql = "UPDATE sys_user SET modules = '$modules' WHERE client_id = $client_id";

0 commit comments

Comments
 (0)