mirror of
https://github.com/mainnika/mongox-go-driver.git
synced 2026-05-22 15:53:36 +00:00
Remove custom err type
err
This commit is contained in:
@@ -2,12 +2,12 @@ package database
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"reflect"
|
||||
|
||||
"go.mongodb.org/mongo-driver/mongo"
|
||||
|
||||
"github.com/mainnika/mongox-go-driver/v2/mongox"
|
||||
"github.com/mainnika/mongox-go-driver/v2/mongox/errors"
|
||||
)
|
||||
|
||||
// Database handler
|
||||
@@ -78,5 +78,5 @@ func (d *Database) GetCollectionOf(document interface{}) mongox.MongoCollection
|
||||
return d.client.Database(d.dbname).Collection(found)
|
||||
}
|
||||
|
||||
panic(errors.InternalErrorf("document %v does not have a collection tag", document))
|
||||
panic(fmt.Errorf("document %v does not have a collection tag", document))
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user