mirror of
				https://github.com/inventree/InvenTree.git
				synced 2025-10-29 20:30:39 +00:00 
			
		
		
		
	reduce regex
This commit is contained in:
		
							
								
								
									
										4
									
								
								tasks.py
									
									
									
									
									
								
							
							
						
						
									
										4
									
								
								tasks.py
									
									
									
									
									
								
							| @@ -502,9 +502,7 @@ def test_translations(c): | |||||||
|     # complie regex |     # complie regex | ||||||
|     reg = re.compile( |     reg = re.compile( | ||||||
|         r"[a-zA-Z0-9]{1}"+  # match any single letter and number |         r"[a-zA-Z0-9]{1}"+  # match any single letter and number | ||||||
|         r"(?![^{]*})"+  # that is not inside curly brackets |         r"(?![^{\(\<]*[}\)\>])"+  # that is not inside curly brackets, brackets or a tag | ||||||
|         r"(?![^\<]*\>)"+  # that is not a tag |  | ||||||
|         r"(?![^\(]*\))"+  # that is not inside brackets |  | ||||||
|         r"(?<![^\%][^\(][)][a-z])"+  # that is not a specially formatted variable with singles |         r"(?<![^\%][^\(][)][a-z])"+  # that is not a specially formatted variable with singles | ||||||
|         r"(?![^\\][\n])"  # that is not a newline |         r"(?![^\\][\n])"  # that is not a newline | ||||||
|     ) |     ) | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user