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

Unified Diff: mojo/public/tools/bindings/generators/mojom_js_generator.py

Issue 2595563004: Mojo JS bindings: fix enum array validation. (Closed)
Patch Set: . Created 4 years 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: mojo/public/tools/bindings/generators/mojom_js_generator.py
diff --git a/mojo/public/tools/bindings/generators/mojom_js_generator.py b/mojo/public/tools/bindings/generators/mojom_js_generator.py
index 0d774a597f138c3ecb66771c08d8d70fedc69238..401af48b39ad4c673bef40e162f9bc017dd0fb78 100644
--- a/mojo/public/tools/bindings/generators/mojom_js_generator.py
+++ b/mojo/public/tools/bindings/generators/mojom_js_generator.py
@@ -234,9 +234,8 @@ def JavaScriptValidateArrayParams(field):
def JavaScriptValidateEnumParams(field):
- nullable = JavaScriptNullableParam(field)
enum_type = JavaScriptType(field.kind)
- return "%s, %s" % (enum_type, nullable)
+ return enum_type
Jay Civelli 2016/12/21 23:14:52 Nit: is the local var needed?
yzshen1 2016/12/21 23:17:36 Done.
def JavaScriptValidateStructParams(field):
nullable = JavaScriptNullableParam(field)
« no previous file with comments | « mojo/public/js/validator.js ('k') | third_party/WebKit/LayoutTests/payments/resources/payment-request-mock.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698