When no page is passed, set page to be 0

fix: when no page is passed, set page to be 0
When no page is passed, set page to be 0fixpage passed set

Committed by scopsy

commit message
fix: when no page is passed, set page to be 0

This fixes a problem where the page was passed as NaN to mongoose and caused strange errors

Editor assessment

The subject states the rule, page defaults to zero when absent, and the body earns real credit by explaining the failure being prevented: the page parameter reached Mongoose as NaN and caused strange errors. That is a genuine why-and-symptom pair in one sentence, exactly what a small fix message should carry, and it lets a reader judge the change without the diff. No scope, a minor gap where api would fit; no footers needed. Hygiene is good: imperative, period-free, no junk. A compact, instructive fix message with only trivial flaws.

Browse categories

More fix examples · Back to search