sql-js / sql-js/sql.js

Database.each() documented return value doesn't match code

Open
#395 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
JavaScript
Stars
13.7k
Forks
1.1k
PR merge metrics
No merged PRs in 30d

Description

Database.each() is documented as returning the Database instance:

Returns:
( Database ) — The database object. Usefull for method chaining

The source code, however, shows that it returns either the result of the done callback or undefined. Either the documentation or the code appears wrong.

Contributor guide

Open the contributing guide

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

Read src/api.js at the linked lines and compare its behavior with the Database.each documentation. Determine whether the implementation or the documented return value is authoritative, then align the affected source or documentation and verify that the API reference matches the resulting behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, sqlite
Domain
database
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.