This commit is contained in:
Robert Hall
2018-09-24 20:49:04 -06:00
parent 46069b2b68
commit 3d2098c250
3 changed files with 9 additions and 10 deletions

View File

@@ -7,7 +7,6 @@ export async function post(req, res) {
res.writeHead(200, { 'Content-Type': 'application/json' });
try {
if (req.body.key === 'username') {
debugger
const found = db.find(req.body.key, req.body.value);
if (found) {
message = 'That username is already in use.';
@@ -18,7 +17,6 @@ export async function post(req, res) {
if (!valid) {
message = 'Email is invalid.';
} else {
debugger
const found = db.find(req.body.key, req.body.value);
if (found) {
message = 'Email is already taken.';