mirror of
https://github.com/status-im/status-react.git
synced 2025-02-17 13:28:04 +00:00
request only one day history from mailserver
This commit is contained in:
parent
31fdb39683
commit
7bab525202
@ -28,7 +28,7 @@
|
|||||||
|
|
||||||
(def one-day (* 24 3600))
|
(def one-day (* 24 3600))
|
||||||
(def seven-days (* 7 one-day))
|
(def seven-days (* 7 one-day))
|
||||||
(def maximum-number-of-attemps 2)
|
(def maximum-number-of-attempts 2)
|
||||||
(def request-timeout 30)
|
(def request-timeout 30)
|
||||||
|
|
||||||
(def connection-timeout
|
(def connection-timeout
|
||||||
@ -208,7 +208,7 @@
|
|||||||
[now-in-s [topic {:keys [last-request]}]]
|
[now-in-s [topic {:keys [last-request]}]]
|
||||||
(let [days (conj
|
(let [days (conj
|
||||||
(into [] (range (max last-request
|
(into [] (range (max last-request
|
||||||
(- now-in-s seven-days))
|
(- now-in-s one-day))
|
||||||
now-in-s
|
now-in-s
|
||||||
one-day))
|
one-day))
|
||||||
now-in-s)
|
now-in-s)
|
||||||
@ -372,7 +372,7 @@
|
|||||||
|
|
||||||
(fx/defn resend-request
|
(fx/defn resend-request
|
||||||
[{:keys [db] :as cofx} {:keys [request-id]}]
|
[{:keys [db] :as cofx} {:keys [request-id]}]
|
||||||
(if (<= maximum-number-of-attemps
|
(if (<= maximum-number-of-attempts
|
||||||
(get-in db [:transport.inbox/current-request :attemps]))
|
(get-in db [:transport.inbox/current-request :attemps]))
|
||||||
(fx/merge cofx
|
(fx/merge cofx
|
||||||
{:db (update db :transport.inbox/current-request dissoc :attemps)}
|
{:db (update db :transport.inbox/current-request dissoc :attemps)}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user