#NEWLINE# def _fix_hijri_gregorian_feb_mismatch( self , date_formats , languages ) : #NEWLINE# #INDENT# for lang_shortname in languages : #NEWLINE# #INDENT# language = default_language_loader . get_language ( lang_shortname ) #NEWLINE# translated = language . translate ( self . source , settings = settings ) #NEWLINE# def _sub_fn( m ) : #NEWLINE# #INDENT# digit = int ( m . group ( 0 ) ) #NEWLINE# return '{:02d}' . format ( ( digit - 10 ) ) #NEWLINE# #UNINDENT# ( fixed_date_string , nreplaced ) = re . subn ( '(?<!\\d)(29|30)' , _sub_fn , translated , 1 ) #NEWLINE# if ( not nreplaced ) : #NEWLINE# #INDENT# continue #NEWLINE# #UNINDENT# date_data = self . _parser_get_date ( fixed_date_string , date_formats , languages ) #NEWLINE# date_obj = date_data . get ( 'date_obj' ) #NEWLINE# if date_obj : #NEWLINE# #INDENT# date_data [ 'date_obj' ] = self . _hijri_to_gregorian ( date_obj . year , date_obj . month , ( date_obj . day + 10 ) , date_obj ) #NEWLINE# return date_data