Fix delete logic in contact view if contact merging is disabled (new)
What is it?
- [x] Bugfix
- [ ] Feature
- [ ] Codebase improvement
Description of the changes in your PR
- If merging is disabled, only delete selected contact from contacts view.
Fixes the following issue(s)
- Fixes https://github.com/stephanritscher/Simple-Contacts/issues/4.
Acknowledgement
- [x] I read the contribution guidelines.
Fixes https://github.com/FossifyOrg/Contacts/issues/106.
I've tested it on emulator, and it doesn't seem to work. I created two contacts with the same name but in different storages and tried to remove one of them (while merging duplicates was turned off) - both got removed.
Thanks for testing. I did a retest as well and found there are three places to delete a contact:
- edit contact view: always deleted a single contact as far as I can tell
- view contact view: this one was corrected by me and the fix seems to work as intended
- list contact view: here deleting one contact will still delete all contacts with same name Did you try to delete the contact from list contact view? I will have a look into this. So far I thought the contacts would be indistinguishable so it wouldn't help to change the behaviour, but I forgot about the option to display the phone numbers.
Did you try to delete the contact from list contact view?
Yes, that's exactly where I've deleted it. I thought it's the same delete logic everywhere.
Yeah, would have been easier that way. If you don't mind to test again - I added the contact list logic and it looked good in my test.
It seems to work fine now.
I'll trust you guys on this one :)