We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent d5e4d30 commit e6df8d2Copy full SHA for e6df8d2
1 file changed
src/result.ts
@@ -251,9 +251,9 @@ export class Result<TValue = Unit, TError = string> {
251
const { value, error, isSuccess } = state;
252
253
if (isSome(value) && !isSuccess) {
254
- throw new Error('Value cannot be defined for failed ResultAll');
+ throw new Error('Value cannot be defined for failed Result');
255
} else if (isSome(error) && isSuccess) {
256
- throw new Error('Error cannot be defined for successful ResultAll');
+ throw new Error('Error cannot be defined for successful Result');
257
} else if (!isSome(value) && !isSome(error)) {
258
throw new Error('Value or Error must be defined');
259
}
0 commit comments