cache.db: Custom contact names are not updated if set to empty
Versions
- OS: Debian 10
- Gajim version: 1.1.92+074e56a8
- GTK version: 3.24.13
- Python-nbxmpp version: 0.9.93
Steps to reproduce the problem
- Change a contact's name via right-click --> manage contact ---> rename
- Clear that custom name by setting it to empty.
- Restart gajim (or let the contact change their status).
Expected behavior
The contact's name should be the one that they themselves entered.
Actual behavior
Instead, gajim is showing the custom name again that the user had overwritten with an empty string before.
Further investigation
I found out that the custom name that a user assigns to a contact via right-click menu is cached in the "roster_entry" table in the cache.db (~/.cache/gajim/cache.db). This entry seemingly is only updated if you set the custom name to a non-empty string.