Antidote-for-Tox / objcTox

No longer maintained
Mozilla Public License 2.0
37 stars 12 forks source link

Bug: Delete friend not found, OSX #148

Closed Chuongv closed 8 years ago

Chuongv commented 8 years ago

In OCTSubmanagerFriends, if a user tries to delete a friend and tox returns "Friend not found", objcTox should remove that friend from realm.

I am not sure how I was able to delete a tox friend without deleting it from realm in the first place. But it's present somehow.

dvor commented 8 years ago

More interesting is to find the reason of having friend in realm only. Maybe tox wasn't saved after adding friend? Or a crash occured somewhere?

Chuongv commented 8 years ago

Ah I figured it out. I did an Xcode clean for mac osx, which does a clean of the tox data, but it doesn't get rid of the realm database. So I had a new tox profile but with a realm database for a different tox file loaded.

dvor commented 8 years ago

What do you mean by "Xcode clean"?

.tox file should be stored together with .realm database in one place.

Chuongv commented 8 years ago

Ah yea you are right. They are saved together. I'll try and reproduce it again.

Chuongv commented 8 years ago

Ah finally figured it out :smile: . If you run the mac tests, it will clear out the tox file in the documents folder but leave the database behind. So when you load up the mac app again from objcTox, it will create a new tox profile but then load the old database.

Chuongv commented 8 years ago

Closing this due to PR #157