mirror of
https://github.com/altlinux/gpupdate.git
synced 2025-01-22 18:04:09 +03:00
Added handling of quotation marks in Preference values
This commit is contained in:
parent
862b3b358b
commit
8a2c9554f7
@ -26,6 +26,10 @@ class DynamicAttributes:
|
||||
def __setattr__(self, key, value):
|
||||
if isinstance(value, Enum):
|
||||
value = str(value)
|
||||
if isinstance(value, str):
|
||||
for q in ["'", "\""]:
|
||||
if any(q in ch for ch in value):
|
||||
value = value.replace(q, "″")
|
||||
self.__dict__[key] = value
|
||||
|
||||
def items(self):
|
||||
|
Loading…
x
Reference in New Issue
Block a user