This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ERROR in (you-get-notifications) (Util.java:177) | |
Uncaught exception, not in assertion. | |
expected: nil | |
actual: java.lang.StackOverflowError: null | |
at clojure.lang.Util.dohasheq (Util.java:177) | |
clojure.lang.Util.hasheq (Util.java:168) | |
clojure.lang.PersistentHashMap.hash (PersistentHashMap.java:120) | |
clojure.lang.PersistentHashMap$TransientHashMap.doAssoc (PersistentHashMap.java:324) | |
clojure.lang.ATransientMap.assoc (ATransientMap.java:64) | |
clojure.lang.PersistentHashMap.create (PersistentHashMap.java:78) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ERROR in (you-get-notifications) (Util.java:177) | |
Uncaught exception, not in assertion. | |
expected: nil | |
actual: java.lang.StackOverflowError: null | |
at clojure.lang.Util.dohasheq (Util.java:177) | |
clojure.lang.Util.hasheq (Util.java:168) | |
clojure.lang.PersistentHashMap.hash (PersistentHashMap.java:120) | |
clojure.lang.PersistentHashMap$TransientHashMap.doAssoc (PersistentHashMap.java:324) | |
clojure.lang.ATransientMap.assoc (ATransientMap.java:64) | |
clojure.lang.PersistentHashMap.create (PersistentHashMap.java:78) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
:cljsbuild {:builds {:app {:source-paths ["src/cljs" "src/cljc"] | |
:compiler {:output-to "target/cljsbuild/public/js/app.js" | |
:externs ["resources/public/js.js" | |
"resources/externs/pica.ext.js" | |
"resources/externs/moment.ext.js" | |
"resources/externs/jquery.ext.js" | |
"resources/externs/jquery-ui.ext.js" | |
"resources/externs/materialize.ext.js" | |
"resources/externs/mdl.ext.js" | |
"resources/externs/lodash.ext.js" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
:figwheel {:http-server-root "public" | |
:compile {:recompile-dependents false} | |
:server-port 3449 | |
:hawk-options {:watcher :polling} | |
:nrepl-port 7002 | |
:css-dirs ["resources/public/css"] | |
:nrepl-middleware ["cemerick.piggieback/wrap-cljs-repl"] | |
:ring-handler im.handler/app} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defn watermark-arguments [{:keys [id] :as message}] | |
[(:watermark message) | |
(:watermark-out message) | |
"bfa.co/" | |
"-font" (str (System/getProperty "user.dir") "/resources/public/webfonts/31D41C_0_0.ttf") | |
"-fill" "white" | |
"-gravity" "west" | |
"-pointsize" "32" | |
"-font" (str (System/getProperty "user.dir") "/resources/public/webfonts/31D41C_0_0.ttf") | |
"-annotate" "+5+25" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defn max-fk-for-org | |
"query runs way too slow" | |
[org] | |
(ffirst | |
(d/q '[:find (max ?fk) | |
:in $ ?org | |
:where | |
[?collection :collection/organization ?org] | |
[?content :content/collection ?collection] | |
[?content :content/fk ?fk]] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defn max-fk [org] | |
(ffirst | |
(d/q '[:find (max ?fk) | |
:in $ ?org | |
:where | |
[?collection :collection/organization ?org] | |
[?content :content/collection ?collection] | |
[?content :content/fk ?fk]] | |
(db/_d) org))) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defn cart-line-items [cid _db & [organization]] | |
(d/q '[:find ?e ?org ?name ?price ?dl_or_ph | |
:in $ ?cart | |
:where | |
[?e :line_item/cart ?cart] | |
[?cart :cart/subtotal ?subtotal] | |
[?e :line_item/content ?content] | |
[?e :line_item/dl_or_ph ?dl_or_ph] | |
[?e :line_item/price ?price] | |
[?content :content/collection ?coll] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(let [c (chan)] | |
(go | |
(let [func (fn [] (>! c "callback"))] | |
(.toDataUrl js/window img (fn [res] | |
(swap! items #(conj % [res name])) | |
(swap! zips-atom #(-> % | |
(assoc-in [(:db/id item) :downloaded] (count @items)))) | |
(func) | |
(do-zip)))) | |
(let [res (<! c)] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(doall | |
(map (fn [[img name]] | |
(let [c (chan)] | |
(go | |
(.toDataUrl js/window img (fn [res] | |
(swap! items #(conj % [res name])) | |
(go | |
(>! c "CALLBACK")) | |
(do-zip))) | |
(let [res (<! c)] |