Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
REST: Don't error if a versioned field we would remove is absent
We remove fields that shouldn't be seen on old versions of the API. This was done with `pop(field name)`, which will throw an exception if the named field is absent from the data. However, sometimes if a patch request is via an old API version, we hit this line without ever having the field present. This is odd, but not harmful and we definitely shouldn't 500. Signed-off-by: Daniel Axtens <[email protected]> [stephenfin: Merge test into bug fix] Signed-off-by: Stephen Finucane <[email protected]> Tested-by: Konstantin Ryabitsev <[email protected]> Fixes: d944f17 ("REST: Use versioning for modified responses") Closes: #423 (cherry picked from commit 5c22f9d)
- Loading branch information