From ef0b2ea34eb788e33d580e849f6fb3ade1661e3e Mon Sep 17 00:00:00 2001 From: Arvind Tiwari Date: Fri, 23 Feb 2018 20:05:24 +0530 Subject: [PATCH] renamed sdd_size -> ssd_size --- opennebula_api/serializers.py | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/opennebula_api/serializers.py b/opennebula_api/serializers.py index 0ce15c36..cc52a15e 100644 --- a/opennebula_api/serializers.py +++ b/opennebula_api/serializers.py @@ -50,7 +50,7 @@ class VirtualMachineSerializer(serializers.Serializer): disk_size = serializers.SerializerMethodField() hdd_size = serializers.SerializerMethodField() - sdd_size = serializers.SerializerMethodField() + ssd_size = serializers.SerializerMethodField() ipv4 = serializers.SerializerMethodField() ipv6 = serializers.SerializerMethodField() vm_id = serializers.IntegerField(read_only=True, source='id') @@ -90,7 +90,9 @@ class VirtualMachineSerializer(serializers.Serializer): ssh_key=ssh_key, specs=specs) except OpenNebulaException as err: - raise serializers.ValidationError("OpenNebulaException occured. {0}".format(err)) + raise serializers.ValidationError( + "OpenNebulaException occured. {0}".format(err) + ) return manager.get_vm(opennebula_id) @@ -165,7 +167,9 @@ class VirtualMachineSerializer(serializers.Serializer): class VMTemplateSerializer(serializers.Serializer): """Serializer to map the VMTemplate instance into JSON format.""" - id = serializers.IntegerField(read_only=True, source='opennebula_vm_template_id') + id = serializers.IntegerField( + read_only=True, source='opennebula_vm_template_id' + ) name = serializers.CharField(read_only=True)