Skip to content

Commit f783183

Browse files
committed
refactor(core): change signature of compress function
1 parent 7acd571 commit f783183

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

project.clj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
(defproject clj-html-compressor "0.0.1"
1+
(defproject clj-html-compressor "0.1.1"
22
:description "Clojure library for html compressing"
33
:url "https://github.com/Atsman/clj-html-compressor"
44
:author "Aleh Atsman (http://www.alehatsman.com)"

src/clj/clj_html_compressor/core.clj

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@
6969
compressor))
7070

7171
(defn compress
72-
([html] (compress {} html))
73-
([config html] (let [config (prepare-config config)
72+
([html] (compress html {}))
73+
([html config] (let [config (prepare-config config)
7474
compressor (html-compressor config)]
7575
(.compress compressor html))))

test/clj/clj_html_compressor/core_test.clj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,5 +96,5 @@
9696
(doseq [test-case test-cases]
9797
(let [sourceHtml (read-file (:source test-case))
9898
resultHtml (read-file (:result test-case))]
99-
(is (= resultHtml (compress (:config test-case) sourceHtml))
99+
(is (= resultHtml (compress sourceHtml (:config test-case)))
100100
(:title test-case))))))

0 commit comments

Comments
 (0)