diff --git a/src/string.ts b/src/string.ts index ca46393d8..1eba8d0d5 100644 --- a/src/string.ts +++ b/src/string.ts @@ -105,7 +105,7 @@ export default class StringSchema< }); } - matches(regex: RegExp, options: MatchOptions | MatchOptions['message']) { + matches(regex: RegExp, options?: MatchOptions | MatchOptions['message']) { let excludeEmptyString = false; let message; let name;