Alexander Pantyuhov 2f7d75c90f Discovery fixes (#432, #434)
No more newline characters in statuses (#463)
Copyable address and key in profile (#462), several fixes
2016-11-17 20:15:46 +02:00

27 lines
586 B
Clojure

(ns status-im.data-store.discovery
(:require [status-im.data-store.realm.discovery :as data-store]))
(defn get-all
[ordering]
(->> (data-store/get-all-as-list ordering)
(mapv #(update % :tags vals))))
(defn save
[discovery]
(data-store/save discovery))
(defn exists?
[message-id]
(data-store/exists? message-id))
(defn save-all
[discoveries]
(data-store/save-all discoveries))
(defn delete
[by ordering critical-count to-delete-count]
(data-store/delete by ordering critical-count to-delete-count))
(defn get-all-tags
[]
(data-store/get-all-tags))