func getProductType()

in products.go [104:110]


func getProductType(ctx context.Context, db *sqlx.DB, id int) (*ProductType, error) {
	productTypes, err := queryProductTypes(ctx, db, &id)
	if err != nil || len(productTypes) == 0 {
		return nil, err
	}
	return &productTypes[0], nil
}