Skip to content

Commit 492bdaa

Browse files
authored
[-] fix webui password hiding regex (#1009)
1 parent 43c5369 commit 492bdaa

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

internal/webui/src/pages/SourcesPage/components/SourcesGrid/components/MaskConnectionString.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@ type MaskedTextProps = {
1111
const mask = (connStr: string) => {
1212
if (connStr.includes("://")) {
1313
return connStr.replace(
14-
/(postgresql:\/\/[^:]+:)([^@]+)(@.*)/,
15-
(_, start, pass, end) => `${start}${"•".repeat(8)}${end}`
14+
/((postgresql|postgres):\/\/[^:]+:)([^@]+)(@.*)/,
15+
(_, start, __, pass, end) => `${start}${"•".repeat(8)}${end}`
1616
);
1717
} else {
1818
return connStr.replace(

0 commit comments

Comments
 (0)