diff options
| author | Shinigami <[email protected]> | 2022-12-31 12:22:38 +0100 |
|---|---|---|
| committer | GitHub <[email protected]> | 2022-12-31 12:22:38 +0100 |
| commit | 2d93e6f14a5ba976f87b71202bc4e011e38ee823 (patch) | |
| tree | 09c569ac0aa920ba090667a938f67416134dca26 /src/modules/string/index.ts | |
| parent | e296ff2d4f6f1aa56fe7c80722257bd0b316b30a (diff) | |
| download | faker-2d93e6f14a5ba976f87b71202bc4e011e38ee823.tar.xz faker-2d93e6f14a5ba976f87b71202bc4e011e38ee823.zip | |
chore: turn on padding-line-between-statements (#1691)
Diffstat (limited to 'src/modules/string/index.ts')
| -rw-r--r-- | src/modules/string/index.ts | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/modules/string/index.ts b/src/modules/string/index.ts index 32f76b72..ab16dc34 100644 --- a/src/modules/string/index.ts +++ b/src/modules/string/index.ts @@ -91,6 +91,7 @@ export class StringModule { if (name === 'constructor' || typeof this[name] !== 'function') { continue; } + this[name] = this[name].bind(this); } } @@ -440,6 +441,7 @@ export class StringModule { const value = placeholder === 'x' ? random : (random & 0x3) | 0x8; return value.toString(16); }; + return RFC4122_TEMPLATE.replace(/[xy]/g, replacePlaceholders); } |
