NubeIO / iot-engine

IoT Engine
5 stars 1 forks source link

CREATE/PATCH Point without specified enum type value #327

Open zero88 opened 4 years ago

zero88 commented 4 years ago

Description PATCH::/api/point/<point_id>

{
  "enabled": false
}

point will be erased some enum field to default enum value due to fallback in null value

{
  "enabled": false,
  "protocol": "UNKNOWN",
  "kind": "UNKNOWN",
  "type": "UNKNOWN"
}

Somehow, it happens on POST:/api/point also although POST response is correct, but GET:/api/point response is erased

Solution