File tree Expand file tree Collapse file tree 1 file changed +10
-18
lines changed
packages/cubejs-schema-compiler/src/compiler Expand file tree Collapse file tree 1 file changed +10
-18
lines changed Original file line number Diff line number Diff line change @@ -221,25 +221,17 @@ export class CubeEvaluator extends CubeSymbols {
221221 }
222222
223223 private prepareHierarchies ( cube : any , errorReporter : ErrorReporter ) : void {
224- const uniqueHierarchyNames = new Set ( ) ;
225224 if ( Object . keys ( cube . hierarchies ) . length ) {
226- cube . evaluatedHierarchies = Object . entries ( cube . hierarchies ) . map ( ( [ name , hierarchy ] ) => {
227- if ( uniqueHierarchyNames . has ( name ) ) {
228- errorReporter . error ( `Duplicate hierarchy name '${ name } ' in cube '${ cube . name } '` ) ;
229- }
230- uniqueHierarchyNames . add ( name ) ;
231-
232- return ( {
233- name,
234- ...( typeof hierarchy === 'object' ? hierarchy : { } ) ,
235- levels : this . evaluateReferences (
236- cube . name ,
237- // @ts -ignore
238- hierarchy . levels ,
239- { originalSorting : true }
240- )
241- } ) ;
242- } ) ;
225+ cube . evaluatedHierarchies = Object . entries ( cube . hierarchies ) . map ( ( [ name , hierarchy ] ) => ( {
226+ name,
227+ ...( typeof hierarchy === 'object' ? hierarchy : { } ) ,
228+ levels : this . evaluateReferences (
229+ cube . name ,
230+ // @ts -ignore
231+ hierarchy . levels ,
232+ { originalSorting : true }
233+ )
234+ } ) ) ;
243235 }
244236
245237 if ( cube . isView && ( cube . includedMembers || [ ] ) . length ) {
You can’t perform that action at this time.
0 commit comments