Fork me on GitHub
#core-async
<
2016-10-17
>
bcbradley23:10:01

Do you guys see anything wrong with this? Would you do it a different way?

(defn valve [sink source pressure]
  (async/go-loop []
    (and (not (nil? (async/<! pressure))) (async/>! sink (async<! source)) (recur))))