Use roots value validator functions.
This commit is contained in:
+2
-2
@@ -151,7 +151,7 @@ func ExpandTaggedEvents(e roots.Event, s *EventSubgraph) {
|
||||
name := tag[0]
|
||||
value := tag[1]
|
||||
|
||||
if name != "e" || !roots.Hex64Pattern.MatchString(value) {
|
||||
if name != "e" || !roots.IsValidID(value) {
|
||||
continue
|
||||
}
|
||||
|
||||
@@ -176,7 +176,7 @@ func ExpandTaggedUsers(e roots.Event, s *EventSubgraph) {
|
||||
name := tag[0]
|
||||
value := tag[1]
|
||||
|
||||
if name != "p" || !roots.Hex64Pattern.MatchString(value) {
|
||||
if name != "p" || !roots.IsValidKey(value) {
|
||||
continue
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user