Revision c0045740
b/ui/templates/networks.html | ||
---|---|---|
748 | 748 |
// search DOM for this network |
749 | 749 |
existing = $('#networks-pane #net-' + network.id); |
750 | 750 |
|
751 |
// if multiple machines exist in the DOM, delete all but one |
|
752 |
// defensive coding - that shouldn't happen normally |
|
753 |
while (existing.length > 1){ |
|
751 |
// if in the DOM exist multiple networks with the same id, |
|
752 |
// delete all but one. |
|
753 |
// Defensive coding - that shouldn't happen normally |
|
754 |
while (existing.length > 1) { |
|
754 | 755 |
existing.remove(); |
755 | 756 |
} |
756 | 757 |
// If network already exists in DOM, update it |
... | ... | |
796 | 797 |
var server_image = "unknown" |
797 | 798 |
} |
798 | 799 |
|
799 |
// if multiple servers exist in public network, delete all but one |
|
800 |
// defensive coding - that shouldn't happen normally |
|
801 |
while (existing_public.length > 1){ |
|
802 |
existing_public.remove(); |
|
803 |
} |
|
804 |
|
|
805 | 800 |
// server was deleted |
806 | 801 |
if (server.status == 'DELETED') { |
807 | 802 |
existing_public.remove(); |
Also available in: Unified diff