Skip to content

Commit c75da3a

Browse files
committed
toString()
1 parent f10e8b5 commit c75da3a

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

playwright/src/main/java/com/microsoft/playwright/impl/UrlMatcher.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,10 +129,12 @@ public int hashCode() {
129129

130130
@Override
131131
public String toString() {
132+
if (glob != null)
133+
return String.format("<glob pattern=\"%s\">", glob);
132134
if (pattern != null)
133135
return String.format("<regex pattern=\"%s\" flags=\"%s\">", pattern.pattern(), toJsRegexFlags(pattern));
134136
if (this.predicate != null)
135137
return "<predicate>";
136-
return String.format("<glob pattern=\"%s\">", glob);
138+
return "<true>";
137139
}
138140
}

0 commit comments

Comments
 (0)