Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Misleading documentation for "regexMatch" #139

Closed
jtagscherer opened this issue Feb 2, 2019 · 0 comments
Closed

Misleading documentation for "regexMatch" #139

jtagscherer opened this issue Feb 2, 2019 · 0 comments

Comments

@jtagscherer
Copy link
Contributor

First of all, thank you for your very helpful template functions!

Unfortunately, the documentation for the regexMatch function is a bit misleading (and contains a typo). It states that the function returns true if the input string matches the regular expression. However, it returns true if the input string contains any match. The whole input string does not have to match the regular expression. Internally, the function uses the regexp package whose documentation states as much.

The accompanying example hints at being a rudimentary email address matcher, further solidifying this incorrect intuition. However, it does not only accept email addresses, but also any other string containing an email address.

I suggest that this part of the documentation should be made a bit more explicit to reduce mistakes by potential template users.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant