added custom goja field mapper to handle all caps identifiers and allowed errors unwrapping

This commit is contained in:
Gani Georgiev
2022-11-30 17:23:00 +02:00
parent 799e1d96f8
commit 0fa5edb0b1
9 changed files with 56 additions and 16 deletions

View File

@@ -651,12 +651,12 @@ func (form *RecordUpsert) Submit(interceptors ...InterceptorFunc) error {
return form.dao.RunInTransaction(func(txDao *daos.Dao) error {
// persist record model
if err := txDao.SaveRecord(form.record); err != nil {
return fmt.Errorf("Failed to save the record: %v", err)
return fmt.Errorf("Failed to save the record: %w", err)
}
// upload new files (if any)
if err := form.processFilesToUpload(); err != nil {
return fmt.Errorf("Failed to process the upload files: %v", err)
return fmt.Errorf("Failed to process the upload files: %w", err)
}
// delete old files (if any)