Bug 1435191 - Enforce limit in additional_backgrounds field. r=jaws draft
authorTim Nguyen <ntim.bugs@gmail.com>
Wed, 18 Jul 2018 23:05:36 +0100
changeset 820102 c3adb3b6133d32df94fd6160176fb45d4a720016
parent 819238 fb1a3b7c94112e9c9d9b71cb0d2ba0fd0f03224a
push id116725
push userbmo:ntim.bugs@gmail.com
push dateWed, 18 Jul 2018 22:06:08 +0000
reviewersjaws
bugs1435191
milestone63.0a1
Bug 1435191 - Enforce limit in additional_backgrounds field. r=jaws MozReview-Commit-ID: E5QuWn48kdm
toolkit/components/extensions/schemas/theme.json
--- a/toolkit/components/extensions/schemas/theme.json
+++ b/toolkit/components/extensions/schemas/theme.json
@@ -47,16 +47,17 @@
         "properties": {
           "images": {
             "type": "object",
             "optional": true,
             "properties": {
               "additional_backgrounds": {
                 "type": "array",
                 "items": { "$ref": "ImageDataOrExtensionURL" },
+                "maxItems": 15,
                 "optional": true
               },
               "headerURL": {
                 "$ref": "ImageDataOrExtensionURL",
                 "optional": true
               },
               "theme_frame": {
                 "$ref": "ImageDataOrExtensionURL",
@@ -545,24 +546,26 @@
                   "type": "string",
                   "enum": [
                     "bottom", "center", "left", "right", "top",
                     "center bottom", "center center", "center top",
                     "left bottom", "left center", "left top",
                     "right bottom", "right center", "right top"
                   ]
                 },
+                "maxItems": 15,
                 "optional": true
               },
               "additional_backgrounds_tiling": {
                 "type": "array",
                 "items": {
                   "type": "string",
                   "enum": ["no-repeat", "repeat", "repeat-x", "repeat-y"]
                 },
+                "maxItems": 15,
                 "optional": true
               }
             },
             "additionalProperties": { "$ref": "UnrecognizedProperty" }
           }
         },
         "additionalProperties": { "$ref": "UnrecognizedProperty" }
       },