Skip to content

Commit

Permalink
Added type support to receiver
Browse files Browse the repository at this point in the history
  • Loading branch information
bwlewis committed Jul 9, 2017
1 parent 2d86a00 commit 5202ce9
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions inst/htmlwidgets/receiver.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ HTMLWidgets.widget({
} else val = e.value;
} else {
// non-standard selection object value (FIXME we should switch to using _extraInfo)
if(x.type && x.type != "object") return;
if(x.lookup)
{
val = x.lookup[x.crosstalk_key.indexOf(e.value.object)];
Expand Down
4 changes: 2 additions & 2 deletions inst/htmlwidgets/transceiver.js
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,8 @@ HTMLWidgets.widget({
else cf({sender: null, value: {object: 0}});
} else
{
if(x.lookup) cf({sender: null, value: x.lookup[0]});
else cf({sender: null, value: 0});
if(x.lookup) cf({sender: null, value: [x.lookup[0]]});
else cf({sender: null, value: [0]});
}
}
},
Expand Down

0 comments on commit 5202ce9

Please sign in to comment.