@@ -71,25 +71,6 @@ module.exports = {
7171 minItems : 1 ,
7272 items : { type : 'string' } ,
7373 } ,
74- disallowedForPatterns : {
75- type : 'array' ,
76- uniqueItems : true ,
77- items : { type : 'string' } ,
78- } ,
79- message : { type : 'string' } ,
80- } ,
81- required : [ 'disallowedFor' ] ,
82- additionalProperties : false ,
83- } ,
84- {
85- type : 'object' ,
86- properties : {
87- propName : { type : 'string' } ,
88- disallowedFor : {
89- type : 'array' ,
90- uniqueItems : true ,
91- items : { type : 'string' } ,
92- } ,
9374 disallowedForPatterns : {
9475 type : 'array' ,
9576 uniqueItems : true ,
@@ -98,10 +79,12 @@ module.exports = {
9879 } ,
9980 message : { type : 'string' } ,
10081 } ,
101- required : [ 'disallowedForPatterns' ] ,
82+ anyOf : [
83+ { required : [ 'disallowedFor' ] } ,
84+ { required : [ 'disallowedForPatterns' ] } ,
85+ ] ,
10286 additionalProperties : false ,
10387 } ,
104-
10588 {
10689 type : 'object' ,
10790 properties : {
@@ -130,25 +113,6 @@ module.exports = {
130113 minItems : 1 ,
131114 items : { type : 'string' } ,
132115 } ,
133- disallowedForPatterns : {
134- type : 'array' ,
135- uniqueItems : true ,
136- items : { type : 'string' } ,
137- } ,
138- message : { type : 'string' } ,
139- } ,
140- required : [ 'disallowedFor' ] ,
141- additionalProperties : false ,
142- } ,
143- {
144- type : 'object' ,
145- properties : {
146- propNamePattern : { type : 'string' } ,
147- disallowedFor : {
148- type : 'array' ,
149- uniqueItems : true ,
150- items : { type : 'string' } ,
151- } ,
152116 disallowedForPatterns : {
153117 type : 'array' ,
154118 uniqueItems : true ,
@@ -157,7 +121,10 @@ module.exports = {
157121 } ,
158122 message : { type : 'string' } ,
159123 } ,
160- required : [ 'disallowedForPatterns' ] ,
124+ anyOf : [
125+ { required : [ 'disallowedFor' ] } ,
126+ { required : [ 'disallowedForPatterns' ] } ,
127+ ] ,
161128 additionalProperties : false ,
162129 } ,
163130 ] ,
0 commit comments