Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.6
parent
9c9d7a3805
commit
cbbdb7bb5f
@@ -5,7 +5,7 @@ export function maskCustomerName(name: string | null): string | null {
|
||||
if (!name) return name;
|
||||
const len = name.length;
|
||||
if (len <= 1) return '*';
|
||||
if (len <= 3) return name[0] + '***';
|
||||
if (len <= 3) return name[0] + '*';
|
||||
if (len <= 6) return name.slice(0, 2) + '***' + name.slice(-1);
|
||||
return name.slice(0, 4) + '***' + name.slice(-2);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user