Skip to content

Commit

Permalink
Fix network equipment memory conversion
Browse files Browse the repository at this point in the history
  • Loading branch information
trasher committed Feb 8, 2024
1 parent 7ac7414 commit 517295c
Showing 1 changed file with 6 additions and 7 deletions.
13 changes: 6 additions & 7 deletions lib/php/Converter.php
Original file line number Diff line number Diff line change
Expand Up @@ -936,13 +936,12 @@ private function convertTo01(array $data): array
}
}
if (isset($data['content']['network_device'])) {
foreach ($data['content']['network_device'] as &$netdev) {
if (isset($netdev['memory'])) {
$netdev['memory'] = $this->convertMemory($netdev['memory']);
}
if (isset($netdev['ram'])) {
$netdev['ram'] = $this->convertMemory($netdev['ram']);
}
$netdev = &$data['content']['network_device'];
if (isset($netdev['memory'])) {
$netdev['memory'] = $this->convertMemory($netdev['memory']);
}
if (isset($netdev['ram'])) {
$netdev['ram'] = $this->convertMemory($netdev['ram']);
}
}

Expand Down

0 comments on commit 517295c

Please sign in to comment.