[#10771] Fix loading of tx history before 10000000th block

This commit is contained in:
Roman Volosovskyi 2020-11-03 18:37:42 +02:00
parent c7b3efe6ad
commit 82aca6bd76
No known key found for this signature in database
GPG Key ID: 0238A4B5ECEE70DE
1 changed files with 4 additions and 3 deletions

View File

@ -158,8 +158,8 @@
(fn [{:keys [min-block] :as acc}
{:keys [block hash]}]
(cond
(or (nil? min-block) (> min-block block))
{:min-block block
(or (nil? min-block) (> min-block (js/parseInt block)))
{:min-block (js/parseInt block)
:min-block-transfers-count 1}
(and (= min-block block)
@ -168,7 +168,8 @@
:else acc))
{:min-block
(get-min-known-block db address)
(when-let [min-block-string (get-min-known-block db address)]
(js/parseInt min-block-string))
:min-block-transfers-count
(min-block-transfers-count db address)}