fix phone number convert (undefined)
This commit is contained in:
parent
2ee7f95df6
commit
ac279cfbdb
1 changed files with 3 additions and 2 deletions
|
|
@ -205,8 +205,9 @@ export function saferKorean(input: string): string {
|
||||||
|
|
||||||
// Process number, unit
|
// Process number, unit
|
||||||
.replace(/(\+\d+[\s\-]+)?([\d\-]+)/g, (_, prefix: string, phone: string) => {
|
.replace(/(\+\d+[\s\-]+)?([\d\-]+)/g, (_, prefix: string, phone: string) => {
|
||||||
if (!phone.includes("-")) return prefix + phone;
|
const all = prefix + phone;
|
||||||
return PhoneNumberKorean.convert(phone);
|
if (!phone.includes("-")) return all;
|
||||||
|
return PhoneNumberKorean.convert(all);
|
||||||
})
|
})
|
||||||
.replace(/([\d,]+)([kKMmgGtTpP][iI]?)[bB]/g, (_, num: string, mod: string) => {
|
.replace(/([\d,]+)([kKMmgGtTpP][iI]?)[bB]/g, (_, num: string, mod: string) => {
|
||||||
// 10kib => 십키비바이트
|
// 10kib => 십키비바이트
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue