fix(dashboard): stop double-masking already-masked API key in list (E2E 3/9 regression) (#4671)

Integrated into release/v3.8.37 — render server-masked key verbatim (drop redundant maskKey call). Note: release's maskKey already guards '****' (since v3.8.34), so this is a safe simplification; added a contract test pinning the **** passthrough invariant (2/2 green, would fail against the pre-guard maskKey = the historical double-mask bug).
This commit is contained in:
Diego Rodrigues de Sa e Souza
2026-06-25 21:41:43 -03:00
committed by GitHub
parent 9f83aa9b93
commit db77db0da3
2 changed files with 40 additions and 2 deletions

View File

@@ -16,7 +16,6 @@ import {
computeApiKeyCounts,
formatUsdCost,
toLocalDateTimeInputValue,
maskKey,
toggleKeyVisibility,
} from "./apiManagerPageUtils";
import type { KeyStatus, KeyType } from "./apiManagerPageUtils";
@@ -987,7 +986,7 @@ export default function ApiManagerPageClient() {
<code className="text-sm text-text-muted font-mono truncate">
{visibleKeys.has(key.id)
? (revealedKeys.get(key.id) ?? key.key)
: maskKey(key.key)}
: key.key}
</code>
{allowKeyReveal ? (
<>