awacke1 commited on
Commit
f14ed15
1 Parent(s): f97e7cc

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -186,7 +186,7 @@ def generate_filename(prompt, file_type):
186
  central = pytz.timezone('US/Central')
187
  safe_date_time = datetime.now(central).strftime("%m%d_%H%M")
188
  replaced_prompt = re.sub(r'[<>:"/\\|?*\n]', ' ', prompt)
189
- safe_prompt = re.sub(r'\s+', ' ', replaced_prompt).strip()[:240]
190
  return f"{safe_date_time}_{safe_prompt}.{file_type}"
191
 
192
 
 
186
  central = pytz.timezone('US/Central')
187
  safe_date_time = datetime.now(central).strftime("%m%d_%H%M")
188
  replaced_prompt = re.sub(r'[<>:"/\\|?*\n]', ' ', prompt)
189
+ safe_prompt = re.sub(r'\s+', ' ', replaced_prompt).strip()[:230]
190
  return f"{safe_date_time}_{safe_prompt}.{file_type}"
191
 
192