From 2d0dcf60a3bc60a16c20b1d66c7ae847a1344bd1 Mon Sep 17 00:00:00 2001 From: erik Date: Thu, 16 May 2024 15:11:12 +0200 Subject: [PATCH] Refactor function names --- src/main/dda/masto_embed/account_mode.cljs | 2 +- src/main/dda/masto_embed/browser.cljs | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/main/dda/masto_embed/account_mode.cljs b/src/main/dda/masto_embed/account_mode.cljs index f5ff8b5..040234a 100644 --- a/src/main/dda/masto_embed/account_mode.cljs +++ b/src/main/dda/masto_embed/account_mode.cljs @@ -87,7 +87,7 @@ (cm/replace-all-matching-values-by-new-value "FAVOURITES_COUNT" favourites_count))) (defn masto->html2 [statuses] - (let [html (b/index-html-hiccup)] + (let [html (b/post-html-hiccup)] (map (fn [status] (let [{:keys [account created_at content media_attachments replies_count reblogs_count favourites_count card url]} status] (-> html diff --git a/src/main/dda/masto_embed/browser.cljs b/src/main/dda/masto_embed/browser.cljs index 1f020a8..599d3a5 100644 --- a/src/main/dda/masto_embed/browser.cljs +++ b/src/main/dda/masto_embed/browser.cljs @@ -20,10 +20,10 @@ (def masto-embed "masto-embed") -(def index-html (rc/inline "dda/masto_embed/resources/post.html")) +(def post-html (rc/inline "dda/masto_embed/resources/post.html")) -(defn index-html-hiccup [] - (h/as-hiccup (h/parse index-html))) +(defn post-html-hiccup [] + (h/as-hiccup (h/parse post-html))) (defn element-from-document-by-name [name] (-> js/document