Skip to content

Commit

Permalink
Merge pull request #2372 from chrismcv/dialog-fix
Browse files Browse the repository at this point in the history
[Dialog] Fix key warnings when not using json action
  • Loading branch information
oliviertassinari committed Dec 5, 2015
2 parents e1f71e5 + b1d8bda commit 615a6b8
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions src/dialog.jsx
Expand Up @@ -265,9 +265,8 @@ const DialogInline = React.createClass({
);
},

_getAction(actionJSON, key) {
_getAction(actionJSON) {
let props = {
key: key,
secondary: true,
onClick: actionJSON.onClick,
onTouchTap: () => {
Expand Down Expand Up @@ -315,15 +314,15 @@ const DialogInline = React.createClass({

//if the current action isn't a react object, create one
if (!React.isValidElement(currentAction)) {
currentAction = this._getAction(currentAction, i);
currentAction = this._getAction(currentAction);
}

actionObjects.push(currentAction);
}

actionContainer = (
<div style={this.prepareStyles(actionStyle)}>
{actionObjects}
{React.Children.toArray(actionObjects)}
</div>
);
}
Expand Down

0 comments on commit 615a6b8

Please sign in to comment.