SMILEConsortium / node-smile-server

3 stars 4 forks source link

SMILE Student Web doesn't validate the user login #40

Closed truedat101 closed 10 years ago

truedat101 commented 10 years ago

While not common to try to login without a username, we don't seem to perform validation of the input. We check that require fields are present, but we submit without bothering to deal with the lack of a username. We should either tell the user to enter a username, or fill in a random name.

Not a system crash but the user gets an ugly error 500.

truedat101 commented 10 years ago

Need to add some Knockout.js validation.

truedat101 commented 10 years ago

The easy fix is to just check before we do a login to see if self.username() === empty or === "". In either case, print the error.