Clean up error returns from functions
- Dominant language
- JavaScript
- Stars
- 197
- Forks
- 32
- PR merge metrics
- No merged PRs in 30d
Description
Currently, the code base has many different ways for functions to report errors:
- `chrome.runtime.lastError`
- `true` for success, stringy error message for failure
- truthy object for success, stringy error message for failure
- `null` for failure, other for success
Regularize these!
Maybe https://github.com/alleycat-at-git/monad/blob/master/js/src/option.js .
Contributor guide
Research direction
Start by inventorying the functions that use the listed error-return conventions and reading the surrounding callers to understand their expectations. Compare the alternatives mentioned in the issue before deciding whether one convention can cover the codebase. Done means the error-reporting behavior is regularized consistently across the affected functions and their callers.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- frontend
- Issue type
- Refactor
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 20/100