mirror of
https://github.com/danog/MadelineProto.git
synced 2024-11-30 10:38:59 +01:00
Another small improvement
This commit is contained in:
parent
4439bfb14a
commit
07f41062b5
@ -649,14 +649,14 @@ final class TL implements TLInterface
|
||||
'pow' => $pow
|
||||
]) {
|
||||
$arguments[$flag] ??= 0;
|
||||
switch ($type) {
|
||||
case 'true':
|
||||
$arguments[$flag] = isset($arguments[$name]) && $arguments[$name] ? $arguments[$flag] | $pow : $arguments[$flag] & ~$pow;
|
||||
unset($arguments[$name]);
|
||||
break;
|
||||
default:
|
||||
$arguments[$flag] = isset($arguments[$name]) && $arguments[$name] !== null ? $arguments[$flag] | $pow : $arguments[$flag] & ~$pow;
|
||||
break;
|
||||
if ($type === 'true') {
|
||||
$arguments[$flag] = isset($arguments[$name]) && $arguments[$name]
|
||||
? $arguments[$flag] | $pow
|
||||
: $arguments[$flag] & ~$pow;
|
||||
} else {
|
||||
$arguments[$flag] = isset($arguments[$name]) && $arguments[$name] !== null
|
||||
? $arguments[$flag] | $pow
|
||||
: $arguments[$flag] & ~$pow;
|
||||
}
|
||||
}
|
||||
foreach ($tl['params'] as $current_argument) {
|
||||
|
Loading…
Reference in New Issue
Block a user