-
Notifications
You must be signed in to change notification settings - Fork 29
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
fix(RC): start timer when receiving messages #1871
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Business logic on the UI layer 😞
No easy testing, and wrong place overall.
On the past there was a similar situation where I suggested that instead of calling the ViewModel
to mark the last read, it should just call a function like notifyLastVisibleMessage
on the ViewModel
and let the ViewModel do everything that is needed based on that.
This is quite the same.
The if/else
should be in the ViewModel. And it shouldn't tell the ViewModel what to do, the function should be neutral. Like onMessageItemVisible
instead of startDeletionTimer
.
Build (dev-debug) available here. Scroll down to Artifacts! |
Build (beta-debug) available here. Scroll down to Artifacts! |
Build 1 succeeded. The build produced the following APK's: |
(cherry picked from commit a4c0b35)
(cherry picked from commit a4c0b35) Co-authored-by: Tommaso Piazza <[email protected]>
PR Submission Checklist for internal contributors
The PR Title
SQPIT-764
The PR Description
What's new in this PR?
Issues
timer not starting when receiving self deleting messages
Solutions
remove an wrong flag for the timer
Dependencies (Optional)
If there are some other pull requests related to this one (e.g. new releases of frameworks), specify them here.
Needs releases with:
Testing
Test Coverage (Optional)
How to Test
Briefly describe how this change was tested and if applicable the exact steps taken to verify that it works as expected.
Notes (Optional)
Specify here any other facts that you think are important for this issue.
Attachments (Optional)
Attachments like images, videos, etc. (drag and drop in the text box)
PR Post Submission Checklist for internal contributors (Optional)
PR Post Merge Checklist for internal contributors
References
feat(conversation-list): Sort conversations by most emojis in the title #SQPIT-764
.