lbryio / lbryio/lbry-android

FileViewFragment and ChannelCommentsFragment have redundant functions

Open
#1,065 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Java
Stars
2.4k
Forks
110
PR merge metrics
No merged PRs in 30d

Description

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
  1. 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

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by comparing the commenting functions in FileViewFragment and ChannelCommentsFragment, including initCommentForm, clearReplyToComment, postComment, and validateAndCheckPostComments. Identify a shared location for the redundant behavior, then verify that the refactoring meets the acceptance criteria, the project builds, and the relevant tests pass.

Written by the indexing model from the issue text.

Assessment

Tech stack
android, java
Domain
mobile
Issue type
Refactor
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.