1
mirror of https://github.com/DarkFlippers/unleashed-firmware.git synced 2025-12-12 12:42:30 +04:00

add some checks for custom flipper name

and update audio ir asset by Amec0e
This commit is contained in:
MX
2022-08-16 09:43:21 +03:00
parent 5ab70b264d
commit a928cb6ed7
6 changed files with 35 additions and 10 deletions

View File

@@ -138,7 +138,7 @@ class Main(App):
environ.get("CUSTOM_FLIPPER_NAME", None)
or ""
)
if (log_custom_fz_name != ""):
if (log_custom_fz_name != "") and (len(log_custom_fz_name) <= 8) and (log_custom_fz_name.isalnum()) and (log_custom_fz_name.isascii()):
self.logger.info(
f"Flipper Custom Name is set:\n\tName: {log_custom_fz_name} : length - {len(log_custom_fz_name)} chars"
)