{"action":"opened","issue":{"url":"https://api.github.com/repos/triforkse/atom-elm-format/issues/4","repository_url":"https://api.github.com/repos/triforkse/atom-elm-format","labels_url":"https://api.github.com/repos/triforkse/atom-elm-format/issues/4/labels{/name}","comments_url":"https://api.github.com/repos/triforkse/atom-elm-format/issues/4/comments","events_url":"https://api.github.com/repos/triforkse/atom-elm-format/issues/4/events","html_url":"https://github.com/triforkse/atom-elm-format/issues/4","id":148804918,"number":4,"title":"With format-on-save, the buffer is temporarily cleared, messing up Undo","user":{"login":"avh4","id":1222,"avatar_url":"https://avatars.githubusercontent.com/u/1222?v=3","gravatar_id":"","url":"https://api.github.com/users/avh4","html_url":"https://github.com/avh4","followers_url":"https://api.github.com/users/avh4/followers","following_url":"https://api.github.com/users/avh4/following{/other_user}","gists_url":"https://api.github.com/users/avh4/gists{/gist_id}","starred_url":"https://api.github.com/users/avh4/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/avh4/subscriptions","organizations_url":"https://api.github.com/users/avh4/orgs","repos_url":"https://api.github.com/users/avh4/repos","events_url":"https://api.github.com/users/avh4/events{/privacy}","received_events_url":"https://api.github.com/users/avh4/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2016-04-16T01:40:52Z","updated_at":"2016-04-16T01:40:52Z","closed_at":null,"body":"To reproduce:\r\n\r\n  - Enable format on save\r\n  - Edit an Elm file\r\n  - Save (causing a format)\r\n  - Press Cmd-Z to undo\r\n\r\nThe entire contents of the file will be empty.  You have to press Cmd-Z a second time to get the previous (unformatted) file back."}}