meilisearch / meilisearch/meilisearch-java
Client methods that return Boolean should return primitive and various invalid string comparisons
Open
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 245
- Forks
- 152
- PR merge metrics
- No merged PRs in 30d
Description
Description
- The Client class has various methods that return Boolean, but there is no real reason to return an object. THe methods should return primitive boolean.
- At various points strings are tested for
""using the==operator, which is not valid.equalsorisEmptyshould be used.
Expected behavior
No behavior anomalies, just best practices.
Current behavior
n/a
Screenshots or Logs
n/a
Environment (please complete the following information):
- OS: n/a
- Meilisearch version: n/a
- meilisearch-java version: 0.20.1
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the Client class and searching its methods for Boolean return types and string comparisons with "" using ==. Update the identified methods and comparisons, then run the project's existing test suite and confirm behavior remains unchanged while methods return primitive boolean values.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- api
- Issue type
- Refactor
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 65/100