File tree Expand file tree Collapse file tree 1 file changed +11
-2
lines changed Expand file tree Collapse file tree 1 file changed +11
-2
lines changed Original file line number Diff line number Diff line change @@ -27,6 +27,12 @@ def transform_params(p):
27
27
"""
28
28
Transform parameters, throwing away any None values
29
29
and convert False and True values to strings
30
+
31
+ Ex:
32
+ {"record": true, "date_created": "2012-01-02"}
33
+
34
+ becomes:
35
+ {"Record": "true", "DateCreated": "2012-01-02"}
30
36
"""
31
37
p = [(format_name (d ), convert_boolean (p [d ])) for d in p if p [d ] is not None ]
32
38
return dict (p )
@@ -63,7 +69,10 @@ def convert_boolean(bool):
63
69
64
70
def convert_case (s ):
65
71
"""
66
- Given a string in snake case, conver to CamelCase
72
+ Given a string in snake case, convert to CamelCase
73
+
74
+ Ex:
75
+ date_created -> DateCreated
67
76
"""
68
77
return '' .join ([a .title () for a in s .split ("_" ) if a ])
69
78
@@ -1213,7 +1222,7 @@ def create(self, **kwargs):
1213
1222
"""
1214
1223
return self .create_instance (transform_params (kwargs ))
1215
1224
1216
- def update (self , sid , ** kwargs ):
1225
+ def update (self , sid , ** kwargs ):
1217
1226
"""
1218
1227
Update an :class:`Application` with the given parameters.
1219
1228
You can’t perform that action at this time.
0 commit comments