Skip to content

Keep track if a chunk has changed

Niels De Graef requested to merge nielsdg/dirty into main

Introduce a property dirty which signifies if a Contacts.Chunk chagned compared to its original value. That way, we can make sure we don't try to save a property that didn't change, saving us some necessary work. Although normally folks does a similar check, it's still good to prevent going into folks (or anything similar) in the first placE.

As a side effect, it solves a problem we currently had with the NicknameChunk: when calling save_to_persona(), it erroneously represented an empty value as both "" and null. Since those are different, it would try to save them and the E-D-S would time out in that case (and throw an appropriate error). As a consequence, when editing a contact, Contacts would always get blocked on the "nickname" property.

Fixes: #271 (closed)

Merge request reports