diff --git a/xlsxwriter/worksheet.py b/xlsxwriter/worksheet.py index 31453c77b..3725ef51d 100644 --- a/xlsxwriter/worksheet.py +++ b/xlsxwriter/worksheet.py @@ -2987,11 +2987,12 @@ def conditional_format( options["formula"] = "FLOOR(%s,1)=TODAY()+1" % start_cell elif options["criteria"] == "last7Days": - options[ - "formula" - ] = "AND(TODAY()-FLOOR(%s,1)<=6,FLOOR(%s,1)<=TODAY())" % ( - start_cell, - start_cell, + options["formula"] = ( + "AND(TODAY()-FLOOR(%s,1)<=6,FLOOR(%s,1)<=TODAY())" + % ( + start_cell, + start_cell, + ) ) elif options["criteria"] == "lastWeek": @@ -3023,11 +3024,12 @@ def conditional_format( ) elif options["criteria"] == "thisMonth": - options[ - "formula" - ] = "AND(MONTH(%s)=MONTH(TODAY()),YEAR(%s)=YEAR(TODAY()))" % ( - start_cell, - start_cell, + options["formula"] = ( + "AND(MONTH(%s)=MONTH(TODAY()),YEAR(%s)=YEAR(TODAY()))" + % ( + start_cell, + start_cell, + ) ) elif options["criteria"] == "nextMonth":