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 @@ -256,25 +256,17 @@ export class CubeEvaluator extends CubeSymbols {
256256 }
257257
258258 private prepareHierarchies ( cube : any , errorReporter : ErrorReporter ) : void {
259- const uniqueHierarchyNames = new Set ( ) ;
260259 if ( Object . keys ( cube . hierarchies ) . length ) {
261- cube . evaluatedHierarchies = Object . entries ( cube . hierarchies ) . map ( ( [ name , hierarchy ] ) => {
262- if ( uniqueHierarchyNames . has ( name ) ) {
263- errorReporter . error ( `Duplicate hierarchy name '${ name } ' in cube '${ cube . name } '` ) ;
264- }
265- uniqueHierarchyNames . add ( name ) ;
266-
267- return ( {
268- name,
269- ...( typeof hierarchy === 'object' ? hierarchy : { } ) ,
270- levels : this . evaluateReferences (
271- cube . name ,
272- // @ts -ignore
273- hierarchy . levels ,
274- { originalSorting : true }
275- )
276- } ) ;
277- } ) ;
260+ cube . evaluatedHierarchies = Object . entries ( cube . hierarchies ) . map ( ( [ name , hierarchy ] ) => ( {
261+ name,
262+ ...( typeof hierarchy === 'object' ? hierarchy : { } ) ,
263+ levels : this . evaluateReferences (
264+ cube . name ,
265+ // @ts -ignore
266+ hierarchy . levels ,
267+ { originalSorting : true }
268+ )
269+ } ) ) ;
278270 }
279271
280272 if ( cube . isView && ( cube . includedMembers || [ ] ) . length ) {
You can’t perform that action at this time.
0 commit comments