Commits

Anonymous committed f4c66d8

move bad-arg# function to util

Comments (0)

Files changed (1)

src/main/clj/org/bituf/sqlrat/util.clj

     (if (or (seq? anything) (set? anything)) (into [] anything)
       (if (map? anything) (into [] (vals anything))
         [anything]))))
+
+
+(defn bad-arg#
+  "Throw IllegalArgumentException with specified arguments. Use this when you
+   encounter bad/invalid parameters."
+  [reason & more]
+  (throw (IllegalArgumentException. (apply str reason more))))
+