oc: Fix asCSSIdentifier in openchange_user_cleanup

The method lacked the check for the initial character, which adds an
underscore at the beginning of the strings that start with a digit.
This commit is contained in:
Juan Vallés 2015-09-14 15:53:07 +02:00
parent 3da6c90bbe
commit 734aba5ddb

View file

@ -268,6 +268,9 @@ def asCSSIdentifier(inputString):
newChars = []
if str.isdigit(inputString[0]):
newChars.append("_")
for c in inputString:
if c in cssEscapingCharMap:
newChars.append(cssEscapingCharMap[c])