File tree Expand file tree Collapse file tree 5 files changed +5
-5
lines changed Expand file tree Collapse file tree 5 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -558,7 +558,7 @@ export class YdbEmbeddedAPI extends AxiosWrapper {
558558 const { schema, ...rest } = params ;
559559
560560 // FIXME: base64 is passed both to params and body to work on versions before and after 24-3
561- return this . post < QueryAPIResponse < Action , Schema > | ErrorResponse > (
561+ return this . post < QueryAPIResponse < Action , Schema > | ErrorResponse | null > (
562562 this . getPath ( '/viewer/json/query' ) ,
563563 { ...rest , base64} ,
564564 { schema, base64} ,
Original file line number Diff line number Diff line change @@ -86,7 +86,7 @@ function getGroupStats(data?: KeyValueRow[] | TStorageStats[]) {
8686}
8787
8888export const parseGroupsStatsQueryResponse = (
89- data : ExecuteQueryResponse < 'modern' > ,
89+ data : ExecuteQueryResponse < 'modern' > | null ,
9090) : ClusterGroupsStats => {
9191 const parsedData = parseQueryAPIExecuteResponse ( data ) . result ;
9292 return getGroupStats ( parsedData ) ;
Original file line number Diff line number Diff line change @@ -258,7 +258,7 @@ export const executeQueryApi = api.injectEndpoints({
258258 }
259259
260260 const data = parseQueryAPIExecuteResponse ( response ) ;
261- data . traceId = response . _meta ?. traceId ;
261+ data . traceId = response ? ._meta ?. traceId ;
262262
263263 const queryStats : QueryStats = { } ;
264264 if ( data . stats ) {
Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ export const explainVersions = {
1313const supportedExplainQueryVersions = Object . values ( explainVersions ) ;
1414
1515export const prepareExplainResponse = (
16- response : ExplainScriptResponse | ExplainQueryResponse ,
16+ response : ExplainScriptResponse | ExplainQueryResponse | null ,
1717) : PreparedExplainResponse => {
1818 const { plan : rawPlan , ast} = parseQueryAPIExplainResponse ( response ) ;
1919
Original file line number Diff line number Diff line change @@ -24,7 +24,7 @@ export const viewSchemaApi = api.injectEndpoints({
2424 return { error : response } ;
2525 }
2626
27- return { data : response . columns || [ ] } ;
27+ return { data : response ? .columns || [ ] } ;
2828 } catch ( error ) {
2929 return { error : error } ;
3030 }
You can’t perform that action at this time.
0 commit comments