Simplify load-plugins with enumeration-seq
This commit is contained in:
parent
9500f2185d
commit
c557fa8478
1 changed files with 2 additions and 4 deletions
|
@ -12,7 +12,5 @@
|
|||
|
||||
(defn load-plugins []
|
||||
(let [plugins (.getResources (ClassLoader/getSystemClassLoader) "plugin.edn")]
|
||||
(loop []
|
||||
(load-plugin (. ^java.net.URL (. plugins nextElement) openStream))
|
||||
(when (.hasMoreElements plugins)
|
||||
(recur)))))
|
||||
(doseq [plugin (enumeration-seq plugins)]
|
||||
(load-plugin (. ^java.net.URL plugin openStream)))))
|
||||
|
|
Loading…
Reference in a new issue