{"action":"created","issue":{"url":"https://api.github.com/repos/vstirbu/fsm-viewer/issues/12","repository_url":"https://api.github.com/repos/vstirbu/fsm-viewer","labels_url":"https://api.github.com/repos/vstirbu/fsm-viewer/issues/12/labels{/name}","comments_url":"https://api.github.com/repos/vstirbu/fsm-viewer/issues/12/comments","events_url":"https://api.github.com/repos/vstirbu/fsm-viewer/issues/12/events","html_url":"https://github.com/vstirbu/fsm-viewer/issues/12","id":308611749,"number":12,"title":"Quoted property names in callbacks object generate no diagram","user":{"login":"AlexandruSimandi","id":7072931,"avatar_url":"https://avatars1.githubusercontent.com/u/7072931?v=4","gravatar_id":"","url":"https://api.github.com/users/AlexandruSimandi","html_url":"https://github.com/AlexandruSimandi","followers_url":"https://api.github.com/users/AlexandruSimandi/followers","following_url":"https://api.github.com/users/AlexandruSimandi/following{/other_user}","gists_url":"https://api.github.com/users/AlexandruSimandi/gists{/gist_id}","starred_url":"https://api.github.com/users/AlexandruSimandi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AlexandruSimandi/subscriptions","organizations_url":"https://api.github.com/users/AlexandruSimandi/orgs","repos_url":"https://api.github.com/users/AlexandruSimandi/repos","events_url":"https://api.github.com/users/AlexandruSimandi/events{/privacy}","received_events_url":"https://api.github.com/users/AlexandruSimandi/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-03-26T15:05:12Z","updated_at":"2018-03-26T15:09:19Z","closed_at":null,"author_association":"NONE","body":"This is not working\r\n```\r\nvar StateMachine = require('fsm-as-promised');\r\n\r\nvar protocol = {\r\n  state: 'unpublished',\r\n  data: {\r\n    omg: 'trafalet'\r\n  }\r\n}\r\n\r\nvar fsm = StateMachine({\r\n  initial: \"unpublished\",\r\n  events: [\r\n    { name: 'publish', from: 'unpublished', to: 'published' }\r\n  ],\r\n  callbacks: {\r\n    //quoted\r\n    \"onpublish\": function (options) {\r\n      console.log('whatever');\r\n    }\r\n  }\r\n}, protocol);\r\n\r\nfsm.publish();\r\n```\r\nThis is working\r\n```\r\nvar StateMachine = require('fsm-as-promised');\r\n\r\nvar protocol = {\r\n  state: 'unpublished',\r\n  data: {\r\n    omg: 'trafalet'\r\n  }\r\n}\r\n\r\nvar fsm = StateMachine({\r\n  initial: \"unpublished\",\r\n  events: [\r\n    { name: 'publish', from: 'unpublished', to: 'published' }\r\n  ],\r\n  callbacks: {\r\n    //unquoted\r\n    onpublish: function (options) {\r\n      console.log('whatever');\r\n    }\r\n  }\r\n}, protocol);\r\n\r\nfsm.publish();\r\n```"},"comment":{"url":"https://api.github.com/repos/vstirbu/fsm-viewer/issues/comments/376200262","html_url":"https://github.com/vstirbu/fsm-viewer/issues/12#issuecomment-376200262","issue_url":"https://api.github.com/repos/vstirbu/fsm-viewer/issues/12","id":376200262,"user":{"login":"AlexandruSimandi","id":7072931,"avatar_url":"https://avatars1.githubusercontent.com/u/7072931?v=4","gravatar_id":"","url":"https://api.github.com/users/AlexandruSimandi","html_url":"https://github.com/AlexandruSimandi","followers_url":"https://api.github.com/users/AlexandruSimandi/followers","following_url":"https://api.github.com/users/AlexandruSimandi/following{/other_user}","gists_url":"https://api.github.com/users/AlexandruSimandi/gists{/gist_id}","starred_url":"https://api.github.com/users/AlexandruSimandi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AlexandruSimandi/subscriptions","organizations_url":"https://api.github.com/users/AlexandruSimandi/orgs","repos_url":"https://api.github.com/users/AlexandruSimandi/repos","events_url":"https://api.github.com/users/AlexandruSimandi/events{/privacy}","received_events_url":"https://api.github.com/users/AlexandruSimandi/received_events","type":"User","site_admin":false},"created_at":"2018-03-26T15:09:19Z","updated_at":"2018-03-26T15:09:19Z","author_association":"NONE","body":"I looked into the code and i cannot seem to spot the source of the bug"}}
{"actor":{"display_login":"AlexandruSimandi"}}