Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support AddToFolder for Multiple Selected Threads #13973

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

Sagar0-0
Copy link
Contributor

@Sagar0-0 Sagar0-0 commented Feb 6, 2025

First time contributor checklist

Contributor checklist

  • Device A, Android X.Y.Z
  • Device B, Android Z.Y
  • Virtual device W, Android Y.Y.Z
  • My contribution is fully baked and ready to be merged as is
  • I ensure that all the open issues my contribution fixes are mentioned in the commit message of my first commit using the Fixes #1234 syntax

Description

Reason:
A user may want to add multiple chats in an existing or new folder, which was impossible YET.
I tested it thoroughly, previously I was having some FOREIGN KEY CONFLICT exception which crashed the app everytime when I try to "select all" chats and add it to an existing folder. This is not reproducing it for me. Let me know if anyone is able to reproduce it.

Next plans:
Remove from Folder for multi-select. Let me know if this sounds good.

I have also observed many initialization improvements in the code that we can improve to make the app opening time faster. Like Lazily adding the callbacks and more. Let me know if those PRs are welcomed.

@Sagar0-0
Copy link
Contributor Author

Sagar0-0 commented Feb 7, 2025

The issue was caused by allowing to add an archived chat to a folder. If an archived chat was added to any folder and then we tried to "select all" chats and then add them to any folder, the app crashed with android.database.sqlite.SQLiteConstraintException: FullCode: 787 | ErrorCode: 19 | ExtendedErrorCode: 3 | Message: FOREIGN KEY constraint failed | ExtraMessage: null.
Fixed this by not allowing "add to folder" from archived chats screen.

@Sagar0-0 Sagar0-0 force-pushed the support-addToFolder-for-multiple-threads branch from f952222 to d4980e0 Compare February 7, 2025 04:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

1 participant