refresh cache store for read tableName

This commit is contained in:
สาธุชน ณุ 2022-10-31 15:01:16 +07:00
parent 788f400957
commit 784d8a1fa8

View File

@ -82,7 +82,7 @@ func Parse(dest interface{}, cacheStore *sync.Map, namer Namer) (*Schema, error)
// ParseWithSpecialTableName get data type from dialector with extra schema table // ParseWithSpecialTableName get data type from dialector with extra schema table
func ParseWithSpecialTableName(dest interface{}, cacheStore *sync.Map, namer Namer, specialTableName string) (*Schema, error) { func ParseWithSpecialTableName(dest interface{}, cacheStore *sync.Map, namer Namer, specialTableName string) (*Schema, error) {
cacheStore = &sync.Map{} // refresh cache store cacheStore = &sync.Map{} // refresh cache store for read tableName
if dest == nil { if dest == nil {
return nil, fmt.Errorf("%w: %+v", ErrUnsupportedDataType, dest) return nil, fmt.Errorf("%w: %+v", ErrUnsupportedDataType, dest)