don't reject partial matches
This commit is contained in:
parent
f4df46080e
commit
19feb050e9
6
hfcs.go
6
hfcs.go
|
@ -143,6 +143,9 @@ func rejectorigin(userid int64, origin string) bool {
|
||||||
}
|
}
|
||||||
filts := getfilters(userid, filtReject)
|
filts := getfilters(userid, filtReject)
|
||||||
for _, f := range filts {
|
for _, f := range filts {
|
||||||
|
if f.IsAnnounce || f.Text != "" {
|
||||||
|
continue
|
||||||
|
}
|
||||||
if f.Actor == origin {
|
if f.Actor == origin {
|
||||||
log.Printf("rejecting origin: %s", origin)
|
log.Printf("rejecting origin: %s", origin)
|
||||||
return true
|
return true
|
||||||
|
@ -155,6 +158,9 @@ func rejectactor(userid int64, actor string) bool {
|
||||||
origin := originate(actor)
|
origin := originate(actor)
|
||||||
filts := getfilters(userid, filtReject)
|
filts := getfilters(userid, filtReject)
|
||||||
for _, f := range filts {
|
for _, f := range filts {
|
||||||
|
if f.IsAnnounce || f.Text != "" {
|
||||||
|
continue
|
||||||
|
}
|
||||||
if f.Actor == actor || (origin != "" && f.Actor == origin) {
|
if f.Actor == actor || (origin != "" && f.Actor == origin) {
|
||||||
log.Printf("rejecting actor: %s", actor)
|
log.Printf("rejecting actor: %s", actor)
|
||||||
return true
|
return true
|
||||||
|
|
Loading…
Reference in New Issue