reduce number of variables and sanity checks 😵

This commit is contained in:
Kevin Jahns
2020-06-09 23:48:27 +02:00
parent 6b0154f046
commit 6dd26d3b48
4 changed files with 69 additions and 75 deletions

View File

@@ -126,7 +126,7 @@ export const findIndexSS = (structs, clock) => {
let right = structs.length - 1
let mid = structs[right]
let midclock = mid.id.clock
if (mid.id.clock === clock) {
if (midclock === clock) {
return right
}
// @todo does it even make sense to pivot the search?