       (condp get (type (:schema spec))
         #{clojure.lang.PersistentArrayMap
           clojure.lang.PersistentHashMap}
-        (filter-keys identity
-                     (map-kv (fn [k v]
-                               (let [v (extract v (->node nodes))]
-                                 (if (instance? schema.core.OptionalKey k)
-                                   (when v
-                                     [(:k k) v])
-                                   [k v])))
-                             (:schema spec)))
+        (if (some schema? (vals (:schema spec)))
+          (filter-keys identity
+                       (map-kv (fn [k v]
+                                 (let [v (extract v (->node nodes))]
+                                   (if (instance? schema.core.OptionalKey k)
+                                     (when v
+                                       [(:k k) v])
+                                     [k v])))
+                               (:schema spec)))
+          (pull (->node nodes) fns))
 
         #{clojure.lang.PersistentVector}
         (map #(extract (first (:schema spec)) %) nodes)


(defrecord Spec [schema extr])

(defprotocol Extractable
  (extract [_ _])
  (text [_])

      'maybe (schema->fn (:schema schema))
      nil)))

(defn schema? [x]
  (:schema x))

(defn pull [x fns]
  ((apply comp (reverse fns)) x))

(defn spec [schema & extr]
  (Spec. schema extr))

(defn schema [schema]
  (Schema. schema))

(def ->spec spec)

