aboutsummaryrefslogtreecommitdiff
path: root/src/gleam_stdlib.mjs
diff options
context:
space:
mode:
Diffstat (limited to 'src/gleam_stdlib.mjs')
-rw-r--r--src/gleam_stdlib.mjs1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/gleam_stdlib.mjs b/src/gleam_stdlib.mjs
index 7c41cdd..1163c6f 100644
--- a/src/gleam_stdlib.mjs
+++ b/src/gleam_stdlib.mjs
@@ -371,6 +371,7 @@ export function utf_codepoint_to_int(utf_codepoint) {
}
export function regex_check(regex, string) {
+ regex.lastIndex = 0;
return regex.test(string);
}