git ssb

1+

Dominic / secure-scuttlebutt



Commit 85ea06e8f97eb056f25b85d39a8d9383454ef98f

better error

Dominic Tarr committed on 2/2/2017, 10:16:31 AM
Parent: 3a87ab0f145263cab848f87d3125febdc5561b9a

Files changed

index.jschanged
index.jsView
@@ -157,9 +157,9 @@
157157 //used by sbot replication plugin
158158 db.latestSequence = function (id, cb) {
159159 db.last.get(function (err, val) {
160160 if(err) cb(err)
161- else if(!val[id]) cb(new Error('not found:'+id))
161 + else if (!val || !val[id]) cb(new Error('not found:'+id))
162162 else cb(null, val[id].sequence)
163163 })
164164 }
165165

Built with git-ssb-web