Skip to content

Commit 6b057c6

Browse files
committed
2 parents faf3330 + 990f06b commit 6b057c6

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

php-client/class.phpipam-api.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -538,6 +538,7 @@ public function set_api_controller ($controller = false) {
538538
* @return void
539539
*/
540540
public function set_api_identifiers ($identifiers) {
541+
$this->api_server_identifiers = false; // clear this to forget any previous settings
541542
if(is_array($identifiers)) {
542543
if(sizeof($identifiers)>0 && !$this->api_encrypt) {
543544
// reset
@@ -547,7 +548,7 @@ public function set_api_identifiers ($identifiers) {
547548
$this->api_server_identifiers = array();
548549
foreach ($identifiers as $cnt=>$i) {
549550
if($cnt==0) { $this->api_server_identifiers['id'] = $i; }
550-
else { $this->api_server_identifiers['id'.$i] = $i; }
551+
else { $this->api_server_identifiers['id'.($cnt+1)] = $i; }
551552
}
552553

553554
}

0 commit comments

Comments
 (0)