-
-
Notifications
You must be signed in to change notification settings - Fork 1k
Closed
Labels
c: refactorPR that affects the runtime behavior, but doesn't add new features or fixes bugsPR that affects the runtime behavior, but doesn't add new features or fixes bugsdeprecationA deprecation was made in the PRA deprecation was made in the PRm: financeSomething is referring to the finance moduleSomething is referring to the finance modulep: 1-normalNothing urgentNothing urgent
Milestone
Description
We want to deprecate the finance.maskedNumber()
method for removal.
Reasons for removal
- The method has/had a bug for 6 months and it hasn't been reported at all -> low/no actual usage.
- Configuring the method is more time and code consuming than just adding the parenthesis and ellipsis manually instead.
- There is no real standard for anonymizing these data. Developers will likely have their own anonymizing function that they use for their actual data.
- The way the data are anonymized is very specific, in most cases the data are replaced by
*
instead of being outright removed. - There are way more data that you might want to mask such as e-mails, ibans, credit card numbers, that cannot be generated by the method.
Suggested workaround
const data = faker.finance.iban(); // "DE31070946979005090431"
const maskedData = data.replace(/(?<=.{4})\w(?=.{2})/g, '*'); // "DE31****************31"
See also
HonzaMac
Metadata
Metadata
Assignees
Labels
c: refactorPR that affects the runtime behavior, but doesn't add new features or fixes bugsPR that affects the runtime behavior, but doesn't add new features or fixes bugsdeprecationA deprecation was made in the PRA deprecation was made in the PRm: financeSomething is referring to the finance moduleSomething is referring to the finance modulep: 1-normalNothing urgentNothing urgent