Skip to content

Commit 3a7b241

Browse files
authored
doc: update the status of match_pattern function. (#32)
Close #7.
1 parent 48757c1 commit 3a7b241

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

README.md

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -73,11 +73,9 @@ local v = jsonschema.generate_validator(schema, {
7373
-- defaults to `cjson.null` (if available) or `nil`
7474
null = null_token,
7575

76-
-- function called to match patterns, defaults to string.find.
77-
-- The JSON schema specification mentions that the validator should obey
78-
-- the ECMA-262 specification but Lua pattern matching library is much more
79-
-- primitive than that. Users might want to use PCRE or other more powerful
80-
-- libraries here
76+
-- function called to match patterns, defaults to `ngx.re.find` in OpenResty
77+
-- or `rex.find` from lrexlib-pcre on other occassions.
78+
-- The pattern given here will obey the ECMA-262 specification.
8179
match_pattern = function(string, patt)
8280
return ... -- boolean value
8381
end,

0 commit comments

Comments
 (0)