lbry-android
lbry-android copied to clipboard
FileViewFragment and ChannelCommentsFragment have redundant functions
The Issue
FileViewFragment and ChannelCommentsFragment have redundant functions relating to commenting. The functions initCommentForm, clearReplyToComment, postComment, validateAndCheckPostComments, and more are almost all the same or differ only slightly. These functions should be moved to one spot to significantly improve code quality and make the app easier to develop.
Acceptance Criteria
- Redundant functions are made not redundant anymore
Definition of Done
- [ ] Tested against acceptance criteria
- [ ] Tested against the assumptions of the user story
- [ ] The project builds without errors
- [ ] Unit tests are written and passing
- [ ] Tests on devices/browsers listed in the issue have passed
- [ ] QA performed & issues resolved
- [ ] Refactoring completed
- [ ] Any configuration or build changes documented
- [ ] Documentation updated
- [ ] Peer Code Review performed
I am going to code a custom compound view for the "new comment form" layout which will move all those methods into a unique class which then it could be inserted into the layouts.