Skip to content

Commit

Permalink
slightly nicer impl
Browse files Browse the repository at this point in the history
  • Loading branch information
StoneCypher committed May 14, 2017
1 parent 39955f3 commit dd98d63
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 6 deletions.
2 changes: 1 addition & 1 deletion package.json
@@ -1,6 +1,6 @@
{
"name": "jssm",
"version": "0.19.0",
"version": "0.19.1",
"description": "A Javascript state machine with a simple API. Well tested, and typed with Flowtype. MIT License.",
"main": "dist/jssm.es5.browserified.js",
"scripts": {
Expand Down
6 changes: 1 addition & 5 deletions src/js/jssm.js
Expand Up @@ -423,11 +423,7 @@ todo comeback

current_action_for(action : mNT) : number | void {
const action_base = this._actions.get(action);
if (action_base) {
return action_base.get(this.state());
} else {
return undefined;
}
return action_base? action_base.get(this.state()) : undefined;
}

current_action_edge_for(action : mNT) : JssmTransition<mNT, mDT> | void {
Expand Down

0 comments on commit dd98d63

Please sign in to comment.