fix log messages

This commit is contained in:
yuli
2024-08-24 20:16:15 +03:00
parent f31bde4cd8
commit 3672158722
2 changed files with 4 additions and 4 deletions

View File

@@ -476,7 +476,7 @@ func (dbobj SQLiteDB) getOneRecord(q string, values []interface{}) (bson.M, erro
defer tx.Rollback()
rows, err := tx.Query(q, values...)
if err == sql.ErrNoRows {
log.Println("nothing found")
log.Println("Nothing found")
return nil, nil
} else if err != nil {
return nil, err
@@ -774,7 +774,7 @@ func (dbobj SQLiteDB) getListDo(q string, values []interface{}) ([]bson.M, error
defer tx.Rollback()
rows, err := tx.Query(q, values...)
if err == sql.ErrNoRows {
log.Println("nothing found")
log.Println("Nothing found")
return nil, nil
} else if err != nil {
return nil, err

View File

@@ -18,7 +18,7 @@ func (e mainEnv) userCreate(w http.ResponseWriter, r *http.Request, ps httproute
if e.conf.Generic.CreateUserWithoutAccessToken == false {
// anonymous user can not create user record, check token
if e.enforceAuth(w, r, event) == "" {
log.Println("failed to create user, access denied, try to configure Create_user_without_access_token\n")
log.Println("Failed to create user, access denied, try to configure Create_user_without_access_token")
return
}
}
@@ -401,7 +401,7 @@ func (e mainEnv) userPrelogin(w http.ResponseWriter, r *http.Request, ps httprou
fmt.Fprintf(w, `{"status":"error","result":"record not found","captchaurl":"%s"}`, captcha)
return
}
log.Println("user record not found, returning ok status")
log.Println("User record not found, returning ok status")
}
w.Header().Set("Content-Type", "application/json; charset=utf-8")
w.WriteHeader(200)