not allowing spaces or double quotes in custom background

This commit is contained in:
Miodec 2022-08-02 21:01:58 +02:00
parent fb4c47792c
commit 26b72d6b6c

View file

@ -1632,7 +1632,7 @@ export function setCustomBackground(value: string, nosave?: boolean): boolean {
(/(https|http):\/\/(www\.|).+\..+\/.+(\.png|\.gif|\.jpeg|\.jpg)/gi.test(
value
) &&
!/[<>]/.test(value)) ||
!/[<> "]/.test(value)||
value == ""
) {
config.customBackground = value;