Skip to content

Commit

Permalink
Use 11-bit mask in Bloom.check (fixes #303)
Browse files Browse the repository at this point in the history
  • Loading branch information
gkaemmer committed Jul 13, 2018
1 parent 4ecae8a commit ae5bcf6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/bloom.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ Bloom.prototype.add = function (e) {
*/
Bloom.prototype.check = function (e) {
e = utils.sha3(e)
var mask = 511 // binary 111111111
var mask = 2047 // binary 11111111111
var match = true

for (var i = 0; i < 3 && match; i++) {
Expand Down

0 comments on commit ae5bcf6

Please sign in to comment.