mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-09-10 01:55:41 -04:00
move hilite method as per code review feedback
This commit is contained in:
@@ -117,6 +117,14 @@ def hide_from_search_engines(f):
|
|||||||
return decorated_function
|
return decorated_function
|
||||||
|
|
||||||
|
|
||||||
|
# Function used for debugging.
|
||||||
|
# Do print(hilite(message)) while debugging, then remove your print statements
|
||||||
|
def hilite(message):
|
||||||
|
ansi_green = "\033[32m"
|
||||||
|
ansi_reset = "\033[0m"
|
||||||
|
return f"{ansi_green}{message}{ansi_reset}"
|
||||||
|
|
||||||
|
|
||||||
# Function to merge two dict or lists with a JSON-like structure into one.
|
# Function to merge two dict or lists with a JSON-like structure into one.
|
||||||
# JSON-like means they can contain all types JSON can: all the main primitives
|
# JSON-like means they can contain all types JSON can: all the main primitives
|
||||||
# plus nested lists or dictionaries.
|
# plus nested lists or dictionaries.
|
||||||
|
|||||||
@@ -22,9 +22,3 @@ def is_less_than_days_ago(date_from_db, number_of_days):
|
|||||||
|
|
||||||
def parse_naive_dt(dt):
|
def parse_naive_dt(dt):
|
||||||
return parser.parse(dt, ignoretz=True)
|
return parser.parse(dt, ignoretz=True)
|
||||||
|
|
||||||
|
|
||||||
def hilite(message):
|
|
||||||
ansi_green = "\033[32m"
|
|
||||||
ansi_reset = "\033[0m"
|
|
||||||
return f"{ansi_green}{message}{ansi_reset}"
|
|
||||||
|
|||||||
Reference in New Issue
Block a user