MCPcopy Create free account
hub / github.com/bytebase/bytebase / getConstantStringValue

Function getConstantStringValue

frontend/src/plugins/cel/logic/resolve.ts:45–53  ·  view source on GitHub ↗
(expr: CELExpr)

Source from the content-addressed store, hash-verified

43};
44
45const getConstantStringValue = (expr: CELExpr): string => {
46 if (
47 expr.exprKind?.case === "constExpr" &&
48 expr.exprKind.value.constantKind?.case === "stringValue"
49 ) {
50 return expr.exprKind.value.constantKind.value;
51 }
52 return "";
53};
54
55const getConstantBoolValue = (expr: CELExpr): boolean => {
56 if (

Callers 3

resolveEqualityExprFunction · 0.85
resolveCompareExprFunction · 0.85
resolveStringExprFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected