Skip to content

Commit 90ae5d0

Browse files
committed
fix optional structs (#17468)
1 parent 062c51a commit 90ae5d0

File tree

1 file changed

+1
-11
lines changed

1 file changed

+1
-11
lines changed

ydb/core/viewer/viewer_query.h

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -472,17 +472,7 @@ class TJsonQuery : public TViewerPipeClient {
472472
if (valueParser.IsNull()) {
473473
jsonOptional = NJson::JSON_NULL;
474474
} else {
475-
switch(valueParser.GetKind()) {
476-
case NYdb::TTypeParser::ETypeKind::Primitive:
477-
jsonOptional = ColumnPrimitiveValueToJsonValue(valueParser);
478-
break;
479-
case NYdb::TTypeParser::ETypeKind::Decimal:
480-
jsonOptional = valueParser.GetDecimal().ToString();
481-
break;
482-
default:
483-
jsonOptional = NJson::JSON_UNDEFINED;
484-
break;
485-
}
475+
jsonOptional = ColumnValueToJsonValue(valueParser);
486476
}
487477
valueParser.CloseOptional();
488478
return jsonOptional;

0 commit comments

Comments
 (0)