dropbox / nsot

Network Source of Truth is an open source IPAM and network inventory database
https://nsot.readthedocs.io
Other
399 stars 66 forks source link

Make a mutable copy of the QueryDict before we try to update it #332

Closed nickpegg closed 6 years ago

nickpegg commented 6 years ago

When Django was upgraded to 1.11 in #321, the QueryDict that gets passed into NsotSerializer.to_internal_value() became immutable. In cases where the site ID would get set on that QeueryDict, this would cause an exception to get thrown (modifying an immutable object).

This fixes that issue and makes a mutable copy of the QueryDict before trying to set the site field.