IcingaCommandArgument: align toPlainObject method

This commit is contained in:
Thomas Gelf 2019-02-15 01:36:33 +01:00
parent 8046510b1f
commit 89d4af564e
1 changed files with 8 additions and 1 deletions

View File

@ -161,7 +161,8 @@ class IcingaCommandArgument extends IcingaObject
$resolved = false,
$skipDefaults = false,
array $chosenProperties = null,
$resolveIds = true
$resolveIds = true,
$keepId = false
) {
if ($resolved) {
throw new RuntimeException(
@ -175,6 +176,12 @@ class IcingaCommandArgument extends IcingaObject
);
}
if ($keepId) {
throw new RuntimeException(
'IcingaCommandArgument does not support $keepId'
);
}
// $resolveIds is misused here
if ($resolveIds) {
return $this->toCompatPlainObject();