Skip to content
This repository was archived by the owner on May 9, 2023. It is now read-only.

Commit 5e033f3

Browse files
committed
fix index.js count > 0
1 parent 17e65a4 commit 5e033f3

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

.gitignore

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
node_modules
2+
package-lock.json

routes/index.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ router.post('/userAdd', function(req, res, next) {
4747
}
4848

4949
var count = rows.length;
50-
if (count > 1) {
50+
if (count > 0) {
5151

5252
var msg = 'Userid already exists.';
5353
res.render('userAdd', { title: 'Add User', msg: msg });

0 commit comments

Comments
 (0)