{"action":"created","issue":{"url":"https://api.github.com/repos/ga-wdi-boston/game-project/issues/308","repository_url":"https://api.github.com/repos/ga-wdi-boston/game-project","labels_url":"https://api.github.com/repos/ga-wdi-boston/game-project/issues/308/labels{/name}","comments_url":"https://api.github.com/repos/ga-wdi-boston/game-project/issues/308/comments","events_url":"https://api.github.com/repos/ga-wdi-boston/game-project/issues/308/events","html_url":"https://github.com/ga-wdi-boston/game-project/issues/308","id":186687068,"number":308,"title":"JS sign-up token auth not working","user":{"login":"jdaly04","id":20216081,"avatar_url":"https://avatars.githubusercontent.com/u/20216081?v=3","gravatar_id":"","url":"https://api.github.com/users/jdaly04","html_url":"https://github.com/jdaly04","followers_url":"https://api.github.com/users/jdaly04/followers","following_url":"https://api.github.com/users/jdaly04/following{/other_user}","gists_url":"https://api.github.com/users/jdaly04/gists{/gist_id}","starred_url":"https://api.github.com/users/jdaly04/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jdaly04/subscriptions","organizations_url":"https://api.github.com/users/jdaly04/orgs","repos_url":"https://api.github.com/users/jdaly04/repos","events_url":"https://api.github.com/users/jdaly04/events{/privacy}","received_events_url":"https://api.github.com/users/jdaly04/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":6,"created_at":"2016-11-02T00:56:16Z","updated_at":"2016-11-02T11:15:01Z","closed_at":null,"body":"I've been trying to figure out for a while now why my \"Sign Up\" button is not working with the API. I tried putting a debugger in the event, but it does not seem to be even reaching that point in my code.  I tried \"grunt test\" (don't know if that would even be helpful in this situation), and it returned 0 issues. \r\n\r\nIn the console, when I click the sign-up button, I fill out the required fields, and I don't get the Object with new user information. I don't get an error message either. \r\nI am inputting the code from HTML and JS auth directory as reference. Any guidance would be greatly appreciated. \r\n\r\nEVENTS.JS CODE for SIGN-UP:\r\n```js\r\n\r\nconst getFormFields = require(`../../../lib/get-form-fields`);\r\n\r\nconst api = require('./api');\r\nconst ui = require('./ui');\r\n\r\nconst onSignUp = function (event) {\r\n  let data = getFormFields(this);\r\n  debugger;\r\n  event.preventDefault();\r\n  api.signUp(data)\r\n    .then(ui.success)\r\n    .catch(ui.failure);\r\n};\r\n```\r\nAPI.JS CODE for SIGN UP:\r\n```js\r\nconst signUp = (data) =>\r\n  $.ajax({\r\n    url: config.host + '/sign-up',\r\n    method: 'POST',\r\n    data,\r\n  });\r\n```\r\n\r\nHTML WITH SIGN UP BUTTON / MODAL:\r\n\r\n```html\r\n      <!-- Button trigger modal -->\r\n                <button type=\"button\" class=\"btn btn-primary btn-lg\" data-toggle=\"modal\" data-target=\"#myModal\">\r\n                SIGN UP!\r\n              </button>\r\n\r\n  <!-- Modal -->\r\n    <div class=\"modal fade\" id=\"myModal\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"sign-up\">\r\n      <div class=\"modal-dialog\" role=\"document\">\r\n        <div class=\"modal-content\">\r\n          <div class=\"modal-header\">\r\n            <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\"><span aria-hidden=\"true\">&times;</span></button>\r\n            <h4 class=\"modal-title\" id=\"sign-up\">Sign Up!</h4>\r\n          </div>\r\n          <div class=\"modal-body\">\r\n            <form id=\"sign-up\">\r\n              <fieldset>\r\n              <div class=\"form-group\">\r\n                <label for=\"sign-up-email\">Email address</label>\r\n                <input name=\"credentials[email]\" type=\"text\" value=\"email\" placeholder=\"Email\">\r\n              </div>\r\n              <div class=\"form-group\">\r\n                <label for=\"exampleInputPassword1\">Password</label>\r\n                <input name=\"credentials[password]\" type=\"password\" value=\"exampleInputPassword1\" placeholder=\"Password\">\r\n              </div>\r\n              <div class=\"form-group\">\r\n                <label for=\"exampleInputPassword1\">Confirm Password</label>\r\n                <input name=\"credentials[password_confirmation]\" type=\"password\" value=\"exampleInputPassword1\" placeholder=\"Confirm Password\">\r\n              </div>\r\n              <button type=\"submit\" class=\"btn btn-default\">Submit</button>\r\n            </form>\r\n          </div>\r\n\r\n```\r\n\r\nMESSAGE I GET IN CONSOLE (Not sure how to format that properly) \r\nabstract-xhr.js:132 XHR finished loading: GET \"http://localhost:7165/sockjs-node/info?t=1478047747339\".AbstractXHRObject._start @ abstract-xhr.js:132(anonymous function) @ abstract-xhr.js:21"},"comment":{"url":"https://api.github.com/repos/ga-wdi-boston/game-project/issues/comments/257836606","html_url":"https://github.com/ga-wdi-boston/game-project/issues/308#issuecomment-257836606","issue_url":"https://api.github.com/repos/ga-wdi-boston/game-project/issues/308","id":257836606,"user":{"login":"raq929","id":13922520,"avatar_url":"https://avatars.githubusercontent.com/u/13922520?v=3","gravatar_id":"","url":"https://api.github.com/users/raq929","html_url":"https://github.com/raq929","followers_url":"https://api.github.com/users/raq929/followers","following_url":"https://api.github.com/users/raq929/following{/other_user}","gists_url":"https://api.github.com/users/raq929/gists{/gist_id}","starred_url":"https://api.github.com/users/raq929/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/raq929/subscriptions","organizations_url":"https://api.github.com/users/raq929/orgs","repos_url":"https://api.github.com/users/raq929/repos","events_url":"https://api.github.com/users/raq929/events{/privacy}","received_events_url":"https://api.github.com/users/raq929/received_events","type":"User","site_admin":false},"created_at":"2016-11-02T11:15:01Z","updated_at":"2016-11-02T11:15:01Z","body":"Yes! Everything here looks reasonable to me. Come see me this morning and we'll get it sorted."}}
{"actor":{"display_login":"raq929"}}