0
0
Fork 0
mirror of https://github.com/renovatebot/renovate.git synced 2025-01-11 05:39:10 +00:00
renovatebot_renovate/lib/util/mask.ts
Sergei Zharinov a7792bc5b4
refactor(typescript): Refactor more files (#12696)
Co-authored-by: Rhys Arkins <rhys@arkins.net>
2021-11-17 09:32:33 +00:00

9 lines
197 B
TypeScript

export function maskToken(str?: string): string {
return str
? [
str.substring(0, 2),
new Array(str.length - 3).join('*'),
str.slice(-2),
].join('')
: '';
}