GitHub user nickva opened a pull request:
https://github.com/apache/couchdb-couch/pull/231
Fix `badarith` error in couch_db:get_db_info call
When folding we account for a previous `null`, `undefined`, or a number.
However
btree:size/1 returns 0, `nil` or a number.
Switched `undefined` to `nil`. Couldn't find where btree:size would ever
return
`undefined`, it seems we meant to use `nil` instead.
COUCHDB-3316
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/cloudant/couchdb-couch couchdb-3316
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/couchdb-couch/pull/231.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #231
----
commit 63ef337475a266379c7208f52f827980e69d1d1b
Author: Nick Vatamaniuc <[email protected]>
Date: 2017-03-03T02:24:52Z
Fix `badarith` error in couch_db:get_db_info call
When folding we account for a previous `null`, `undefined`, or a number.
However
btree:size/1 returns 0, `nil` or a number.
Switched `undefined` to `nil`. Couldn't find where btree:size would ever
return
`undefined`, it seems we meant to use `nil` instead.
COUCHDB-3316
----
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---