1ef4425
Branches > main > 1ef4425 > files
Don't allow nil in table writers
Commit: 1ef4425d942c320714da2c925601ea4fc18dbaef
Parent: c9bd266
1 changed file:
src/net/bowmap/server/protocol/writers.clj view file
@@ -55,9 +55,9 @@ (defn to-writer "Attempts to coerces 'writer' into a writer. Throws if it cannot. Vectors with pairs of [:key writer] are turned into tables writers.- Nil is coerced to the empty table writer."+ Nil is not a valid writer." [writer] (cond- (or (vector? writer) (nil? writer)) (table-> writer)+ (vector? writer) (table-> writer) (fn? writer) writer :else (throw (IllegalArgumentException. (str "Cannot coerce into writer: " (pr-str writer))))))