Skip to content
Browse files

Improve implementation of clojure.string/blank?

  • Loading branch information...
1 parent 0023c7a commit ae466b23f42f4e4bcd7d0010c54e103f4b3ef0f8 @edtsech edtsech committed with David Nolen Sep 28, 2012
Showing with 1 addition and 7 deletions.
  1. +1 −7 src/cljs/clojure/string.cljs
View
8 src/cljs/clojure/string.cljs
@@ -133,13 +133,7 @@
(defn blank?
"True is s is nil, empty, or contains only whitespace."
[s]
- (let [s (str s)]
- (if (or
- (not s)
- (= "" s)
- (re-matches #"\s+" s))
- true
- false)))
+ (gstring/isEmptySafe s))
(defn escape
"Return a new string, using cmap to escape each character ch

0 comments on commit ae466b2

Please sign in to comment.
Something went wrong with that request. Please try again.