Smush ds removal

This commit is contained in:
Michael DeHaan 2014-07-24 21:16:24 -04:00 committed by James Cammarata
parent b8a4ba26f0
commit 8d42f5cbfa
3 changed files with 10 additions and 45 deletions

View file

@ -149,3 +149,9 @@ def split_args(args):
params = [x.decode('utf-8') for x in params]
return params
def unquote(data):
''' removes first and last quotes from a string, if the string starts and ends with the same quotes '''
if len(data) > 0 and (data[0] == '"' and data[-1] == '"' or data[0] == "'" and data[-1] == "'"):
return data[1:-1]
return data