def _normalize_dir(string):
 return re.sub('\\\\$', '', string.lower())

def _normalize_dir ( string ) : return re . sub ( '\\\\$' , '' , string . lower ( ) )
normalize the directory to make comparison possible .