fix: generate sql incorrect when use soft_delete and only one OR
This commit is contained in:
		
							parent
							
								
									d69be45dd2
								
							
						
					
					
						commit
						8846f34747
					
				@ -94,10 +94,14 @@ func And(exprs ...Expression) Expression {
 | 
				
			|||||||
		return nil
 | 
							return nil
 | 
				
			||||||
	}
 | 
						}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	if _, ok := exprs[0].(OrConditions); !ok && len(exprs) == 1 {
 | 
						if len(exprs) == 1 {
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							if _, ok := exprs[0].(OrConditions); !ok {
 | 
				
			||||||
			return exprs[0]
 | 
								return exprs[0]
 | 
				
			||||||
		}
 | 
							}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
						}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	return AndConditions{Exprs: exprs}
 | 
						return AndConditions{Exprs: exprs}
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user