mirror of
https://github.com/toast-ts/Daggerbot-TS.git
synced 2024-11-17 04:10:59 -05:00
5 lines
221 B
TypeScript
5 lines
221 B
TypeScript
export default (text:string)=>{
|
|
const dirSlash = process.platform === 'linux' ? '\/' : '\\';
|
|
return text?.replace(/(?<=\/Users\/|\/media\/)[^/]+/g, match=>'・'.repeat(match.length)).split(dirSlash).join(dirSlash);
|
|
}
|