Frank Kobzik has uploaded a new change for review. Change subject: frontend: ClassCastException in VmSnapshotListModel fix ......................................................................
frontend: ClassCastException in VmSnapshotListModel fix The change in AsyncDataProvider.GetCustomPropertiesList in ada6bac1 caused ClassCastException. This patch fixes handling result of this method in VmSnapshotListModel. Change-Id: Ie23f1994d218742133a7d963173e416d8e94cfcc Signed-off-by: Frantisek Kobzik <[email protected]> --- M frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/vms/VmSnapshotListModel.java 1 file changed, 2 insertions(+), 14 deletions(-) git pull ssh://gerrit.ovirt.org:29418/ovirt-engine refs/changes/84/13784/1 diff --git a/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/vms/VmSnapshotListModel.java b/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/vms/VmSnapshotListModel.java index 205e78b..7410ad4 100644 --- a/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/vms/VmSnapshotListModel.java +++ b/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/vms/VmSnapshotListModel.java @@ -229,20 +229,8 @@ @Override public void OnSuccess(Object target, Object returnValue) { VmSnapshotListModel model = (VmSnapshotListModel) target; - if (returnValue != null) - { - model.setCustomPropertiesKeysList(new HashMap<Version, ArrayList<String>>()); - HashMap<Version, String> dictionary = - (HashMap<Version, String>) returnValue; - for (Map.Entry<Version, String> keyValuePair : dictionary.entrySet()) - { - model.getCustomPropertiesKeysList().put(keyValuePair.getKey(), - new ArrayList<String>()); - for (String s : keyValuePair.getValue().split("[;]", -1)) //$NON-NLS-1$ - { - model.getCustomPropertiesKeysList().get(keyValuePair.getKey()).add(s); - } - } + if (returnValue != null) { + model.setCustomPropertiesKeysList((HashMap<Version, ArrayList<String>>) returnValue); } } })); -- To view, visit http://gerrit.ovirt.org/13784 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ie23f1994d218742133a7d963173e416d8e94cfcc Gerrit-PatchSet: 1 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Frank Kobzik <[email protected]> _______________________________________________ Engine-patches mailing list [email protected] http://lists.ovirt.org/mailman/listinfo/engine-patches
