Skip to content

Commit

Permalink
do not force all refs to nil
Browse files Browse the repository at this point in the history
this merges in an unconventional manner (from right to left) since
user supplied attrs are fed first to merge-props.
  • Loading branch information
pyr committed Sep 3, 2014
1 parent 174a383 commit 1de9c3c
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/om_bootstrap/util.cljs
Original file line number Diff line number Diff line change
Expand Up @@ -71,13 +71,14 @@
handles :on-select :on-click, :on-blur, kebab-cased as om-tools
prefers."
(let [merge-class (fn [l r] (str l " " r))
orig-fn (fn [l r] (or l r))
empty-fn (fn [_ _] nil)]
{:className merge-class
:class merge-class
:style merge
:children empty-fn
:key empty-fn
:ref empty-fn
:ref orig-fn
:on-select chain-fns
:on-click chain-fns
:on-blur chain-fns}))
Expand Down

0 comments on commit 1de9c3c

Please sign in to comment.