mirror of
https://github.com/monkeytypegame/monkeytype.git
synced 2025-11-19 07:10:49 +08:00
parent
eba4b92305
commit
2e77cb38ff
1 changed files with 5 additions and 0 deletions
|
|
@ -75,6 +75,11 @@ function save(): boolean {
|
|||
return false;
|
||||
}
|
||||
|
||||
if (text.length === 0) {
|
||||
Notifications.add("Custom text can't be empty", 0);
|
||||
return false;
|
||||
}
|
||||
|
||||
text = text.replace(/( *(\r\n|\r|\n) *)/g, "\n ");
|
||||
|
||||
CustomText.setCustomText(name, text, checkbox);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue