Continued:
- you can directly use constant($var) instead of this switch() Signed-off-by: Roland Häder <roland@mxchange.org>
This commit is contained in:
parent
fe1e7b92f2
commit
69ac6feff7
1 changed files with 1 additions and 13 deletions
|
@ -1316,20 +1316,8 @@ class PortableContact
|
|||
$version = $data->version;
|
||||
$site_name = $data->site_name;
|
||||
$info = $data->info;
|
||||
$register_policy_str = $data->register_policy;
|
||||
$register_policy = constant($data->register_policy);
|
||||
$platform = $data->platform;
|
||||
|
||||
switch ($register_policy_str) {
|
||||
case "REGISTER_CLOSED":
|
||||
$register_policy = REGISTER_CLOSED;
|
||||
break;
|
||||
case "REGISTER_APPROVE":
|
||||
$register_policy = REGISTER_APPROVE;
|
||||
break;
|
||||
case "REGISTER_OPEN":
|
||||
$register_policy = REGISTER_OPEN;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue