The <Update an Identity> route overwrites the `pub...
# ory-network
f
The Update an Identity route overwrites the
public_metadata
back to
null
if no value is provided in the payload. This seems like a bug since it is an optional value. I would expect it to leave the existing value unchanged if no value is provided. Should I log a bug, or is this the expected behaviour?
l
Though it is a
PUT
and not a
PATCH
.
r
This is expected behavior:
PUT
replaces the exisitng entity in it’s entirety with a new one.
l
Except it doesn’t overwrite the
credentials
. So the behaviour is a bit inconsistent.
And some of the “required” properties e.g.
schema_id
can be omitted. I think the behaviour is fine, but the documentation could be a bit a more clear.
r
That’s fair 😄