Skip to content

Commit c2e8442

Browse files
committed
Typo
1 parent 4f2c039 commit c2e8442

File tree

2 files changed

+4
-5
lines changed

2 files changed

+4
-5
lines changed

packages/react/src/ReactTaint.js

+2-3
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ export function taintUniqueValue(
6767
(typeof lifetime !== 'object' && typeof lifetime !== 'function')
6868
) {
6969
throw new Error(
70-
'To taint a value, a life time must be defined by passing an object that holds ' +
70+
'To taint a value, a lifetime must be defined by passing an object that holds ' +
7171
'the value.',
7272
);
7373
}
@@ -95,8 +95,7 @@ export function taintUniqueValue(
9595
throw new Error(
9696
'Cannot taint a ' +
9797
kind +
98-
' because the value is too general and cannot be ' +
99-
'a secret by',
98+
' because the value is too general and not unique enough to block globally.',
10099
);
101100
}
102101
const existingEntry = TaintRegistryValues.get(entryValue);

scripts/error-codes/codes.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -478,9 +478,9 @@
478478
"490": "Expected to see a Suspense boundary in this slot. The tree doesn't match so React will fallback to client rendering.",
479479
"491": "It should not be possible to postpone both at the root of an element as well as a slot below. This is a bug in React.",
480480
"492": "The \"react\" package in this environment is not configured correctly. The \"react-server\" condition must be enabled in any environment that runs React Server Components.",
481-
"493": "To taint a value, a life time must be defined by passing an object that holds the value.",
481+
"493": "To taint a value, a lifetime must be defined by passing an object that holds the value.",
482482
"494": "taintUniqueValue cannot taint objects or functions. Try taintObjectReference instead.",
483-
"495": "Cannot taint a %s because the value is too general and cannot be a secret by",
483+
"495": "Cannot taint a %s because the value is too general and not unique enough to block globally.",
484484
"496": "Only objects or functions can be passed to taintObjectReference. Try taintUniqueValue instead.",
485485
"497": "Only objects or functions can be passed to taintObjectReference."
486486
}

0 commit comments

Comments
 (0)