File tree Expand file tree Collapse file tree 2 files changed +6
-4
lines changed
packages/cubejs-client-core/src Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -10,15 +10,17 @@ export type SqlData = {
1010 rollupMatchResults : any [ ] ;
1111} ;
1212
13+ type SqlQueryWrapper = { sql : SqlData } ;
14+
1315export default class SqlQuery {
14- private readonly sqlQuery : SqlData ;
16+ private readonly sqlQuery : SqlQueryWrapper ;
1517
16- public constructor ( sqlQuery : SqlData ) {
18+ public constructor ( sqlQuery : SqlQueryWrapper ) {
1719 this . sqlQuery = sqlQuery ;
1820 }
1921
2022 public rawQuery ( ) : SqlData {
21- return this . sqlQuery ;
23+ return this . sqlQuery . sql ;
2224 }
2325
2426 public sql ( ) : string {
Original file line number Diff line number Diff line change @@ -627,7 +627,7 @@ class CubeApi {
627627 query,
628628 signal : options ?. signal
629629 } ) ,
630- ( response : any ) => ( Array . isArray ( response ) ? response . map ( ( body ) => new SqlQuery ( body . sql ) ) : new SqlQuery ( response . sql ) ) ,
630+ ( response : any ) => ( Array . isArray ( response ) ? response . map ( ( body ) => new SqlQuery ( body ) ) : new SqlQuery ( response ) ) ,
631631 options ,
632632 callback
633633 ) ;
You can’t perform that action at this time.
0 commit comments