jamro / jsbattle

JavaScript Programming Game (inspired by RoboCode)
http://jsbattle.jmrlab.com
MIT License
105 stars 47 forks source link

Fix register after first login and some docs links #34

Closed redbugz closed 3 years ago

redbugz commented 3 years ago

When first signing in, clicking Save Profile on the register screen was ignored the first time, and you had to click it a second time for it to work. It appears that because the form got submitted just after the PROFILE_REGISTER_REQUEST was active, it would refresh the page and lose that request, so the profile didn't get updated to registered: true. This adds a preventDefault to the form submission so that no page refresh occurs and the profile register request can succeed the first time.

Also fixed a few broken links in the docs to the algorithms and configuration pages and a few typos. And added some subproperties to the AuthMethods API definition, just to help specify the shape of the object.