@@ -54,18 +54,6 @@ function getCalleeMemberNode(node) {
5454  return  null 
5555} 
5656
57- const  OBJECT_OPTION_SCHEMA  =  { 
58-   type : 'object' , 
59-   properties : { 
60-     ignores : { 
61-       type : 'array' , 
62-       items : {  type : 'string'  } , 
63-       uniqueItems : true , 
64-       additionalItems : false 
65-     } 
66-   } , 
67-   additionalProperties : false 
68- } 
6957module . exports  =  { 
7058  meta : { 
7159    type : 'suggestion' , 
@@ -75,24 +63,23 @@ module.exports = {
7563      url : 'https://eslint.vuejs.org/rules/custom-event-name-casing.html' 
7664    } , 
7765    fixable : null , 
78-     schema : { 
79-       anyOf : [ 
80-         { 
81-           type : 'array' , 
82-           items : [ 
83-             { 
84-               enum : ALLOWED_CASE_OPTIONS 
85-             } , 
86-             OBJECT_OPTION_SCHEMA 
87-           ] 
66+     schema : [ 
67+       { 
68+         enum : ALLOWED_CASE_OPTIONS 
69+       } , 
70+       { 
71+         type : 'object' , 
72+         properties : { 
73+           ignores : { 
74+             type : 'array' , 
75+             items : {  type : 'string'  } , 
76+             uniqueItems : true , 
77+             additionalItems : false 
78+           } 
8879        } , 
89-         // For backward compatibility 
90-         { 
91-           type : 'array' , 
92-           items : [ OBJECT_OPTION_SCHEMA ] 
93-         } 
94-       ] 
95-     } , 
80+         additionalProperties : false 
81+       } 
82+     ] , 
9683    messages : { 
9784      unexpected : "Custom event name '{{name}}' must be {{caseType}}." 
9885    } 
@@ -102,13 +89,8 @@ module.exports = {
10289    /** @type  {Map<ObjectExpression|Program, {contextReferenceIds:Set<Identifier>,emitReferenceIds:Set<Identifier>}> } */ 
10390    const  setupContexts  =  new  Map ( ) 
10491    let  emitParamName  =  '' 
105-     const  options  = 
106-       context . options . length  ===  1  &&  typeof  context . options [ 0 ]  !==  'string' 
107-         ? // For backward compatibility 
108-           [ undefined ,  context . options [ 0 ] ] 
109-         : context . options 
110-     const  caseType  =  options [ 0 ]  ||  DEFAULT_CASE 
111-     const  objectOption  =  options [ 1 ]  ||  { } 
92+     const  caseType  =  context . options [ 0 ]  ||  DEFAULT_CASE 
93+     const  objectOption  =  context . options [ 1 ]  ||  { } 
11294    const  caseChecker  =  casing . getChecker ( caseType ) 
11395    /** @type  {RegExp[] } */ 
11496    const  ignores  =  ( objectOption . ignores  ||  [ ] ) . map ( toRegExp ) 
0 commit comments