Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2)

Unified Diff: tools/json_schema_compiler/model.py

Issue 9617010: Move chrome.downloads out of experimental to dev (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 8 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: tools/json_schema_compiler/model.py
diff --git a/tools/json_schema_compiler/model.py b/tools/json_schema_compiler/model.py
index 23b77c6d1402dba8ee88cf0d33b7f78b28b0ef81..31bc75401f1201f4d150656a9590fae995a0502f 100644
--- a/tools/json_schema_compiler/model.py
+++ b/tools/json_schema_compiler/model.py
@@ -190,7 +190,8 @@ class Property(object):
elif '$ref' in json:
self.ref_type = json['$ref']
self.type_ = PropertyType.REF
- elif 'enum' in json:
+ elif 'enum' in json and all(isinstance(value, basestring)
+ for value in json['enum']):
not at google - send to devlin 2012/06/12 18:34:38 Could you move the second check inside this block?
benjhayden 2012/06/12 20:15:42 Actually, I did this specifically so that it would
self.enum_values = []
for value in json['enum']:
self.enum_values.append(value)

Powered by Google App Engine
This is Rietveld 408576698