fix variable shadowing (#5212)
Co-authored-by: Shenao Zhang <shenao.zhang@shopee.com>
This commit is contained in:
		
							parent
							
								
									ea8509b777
								
							
						
					
					
						commit
						8333844f71
					
				
							
								
								
									
										4
									
								
								gorm.go
									
									
									
									
									
								
							
							
						
						
									
										4
									
								
								gorm.go
									
									
									
									
									
								
							| @ -124,8 +124,8 @@ func Open(dialector Dialector, opts ...Option) (db *DB, err error) { | ||||
| 
 | ||||
| 	for _, opt := range opts { | ||||
| 		if opt != nil { | ||||
| 			if err := opt.Apply(config); err != nil { | ||||
| 				return nil, err | ||||
| 			if applyErr := opt.Apply(config); applyErr != nil { | ||||
| 				return nil, applyErr | ||||
| 			} | ||||
| 			defer func(opt Option) { | ||||
| 				if errr := opt.AfterInitialize(db); errr != nil { | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user
	 ZhangShenao
						ZhangShenao