mirror of
				https://github.com/django/django.git
				synced 2025-10-31 01:25:32 +00:00 
			
		
		
		
	[1.11.x] Used constant instead of hard-coded value for max index name length
Refs #26709
Backport of e7033e00f8 from master
			
			
This commit is contained in:
		
				
					committed by
					
						 Markus Holtermann
						Markus Holtermann
					
				
			
			
				
	
			
			
			
						parent
						
							293ff4d2b4
						
					
				
				
					commit
					c654ead898
				
			| @@ -108,7 +108,7 @@ class Index(object): | |||||||
|             column_names[0][:7], |             column_names[0][:7], | ||||||
|             '%s_%s' % (self._hash_generator(*hash_data), self.suffix), |             '%s_%s' % (self._hash_generator(*hash_data), self.suffix), | ||||||
|         ) |         ) | ||||||
|         assert len(self.name) <= 30, ( |         assert len(self.name) <= MAX_NAME_LENGTH, ( | ||||||
|             'Index too long for multiple database support. Is self.suffix ' |             'Index too long for multiple database support. Is self.suffix ' | ||||||
|             'longer than 3 characters?' |             'longer than 3 characters?' | ||||||
|         ) |         ) | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user