added debug log for the invalid uploaded file(s)
This commit is contained in:
@@ -4,6 +4,7 @@ import (
|
|||||||
"encoding/json"
|
"encoding/json"
|
||||||
"errors"
|
"errors"
|
||||||
"fmt"
|
"fmt"
|
||||||
|
"log"
|
||||||
"net/http"
|
"net/http"
|
||||||
"regexp"
|
"regexp"
|
||||||
"strconv"
|
"strconv"
|
||||||
@@ -201,6 +202,10 @@ func (form *RecordUpsert) LoadData(r *http.Request) error {
|
|||||||
// check if there are any new uploaded form files
|
// check if there are any new uploaded form files
|
||||||
files, err := rest.FindUploadedFiles(r, key)
|
files, err := rest.FindUploadedFiles(r, key)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
if form.app.IsDebug() {
|
||||||
|
log.Printf("%q uploaded file error: %v\n", key, err)
|
||||||
|
}
|
||||||
|
|
||||||
continue // skip invalid or missing file(s)
|
continue // skip invalid or missing file(s)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user