little more cleanup, leave todo where we have unfinished business
This commit is contained in:
parent
de36230cec
commit
70354077f3
2
hfcs.go
2
hfcs.go
|
@ -145,6 +145,7 @@ func stealthmode(userid int64, r *http.Request) bool {
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// todo
|
||||||
func matchfilter(h *Honk, filts []*Filter) bool {
|
func matchfilter(h *Honk, filts []*Filter) bool {
|
||||||
origin := originate(h.XID)
|
origin := originate(h.XID)
|
||||||
for _, f := range filts {
|
for _, f := range filts {
|
||||||
|
@ -172,6 +173,7 @@ func skipMedia(xonk *Honk) bool {
|
||||||
return matchfilter(xonk, filts)
|
return matchfilter(xonk, filts)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// todo
|
||||||
func unsee(filts []*Filter, h *Honk) string {
|
func unsee(filts []*Filter, h *Honk) string {
|
||||||
return ""
|
return ""
|
||||||
}
|
}
|
||||||
|
|
23
web.go
23
web.go
|
@ -1252,6 +1252,7 @@ func zonkzone(w http.ResponseWriter, r *http.Request) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// todo
|
||||||
func zonkzonk(w http.ResponseWriter, r *http.Request) {
|
func zonkzonk(w http.ResponseWriter, r *http.Request) {
|
||||||
userinfo := login.GetUserInfo(r)
|
userinfo := login.GetUserInfo(r)
|
||||||
itsok := r.FormValue("itsok")
|
itsok := r.FormValue("itsok")
|
||||||
|
@ -1264,28 +1265,6 @@ func zonkzonk(w http.ResponseWriter, r *http.Request) {
|
||||||
http.Redirect(w, r, "/zonkzone", http.StatusSeeOther)
|
http.Redirect(w, r, "/zonkzone", http.StatusSeeOther)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
wherefore := r.FormValue("wherefore")
|
|
||||||
name := r.FormValue("name")
|
|
||||||
if name == "" {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
switch wherefore {
|
|
||||||
case "zonker":
|
|
||||||
case "zomain":
|
|
||||||
case "zonvoy":
|
|
||||||
case "zord":
|
|
||||||
case "zilence":
|
|
||||||
case "zoggle":
|
|
||||||
default:
|
|
||||||
return
|
|
||||||
}
|
|
||||||
db := opendatabase()
|
|
||||||
db.Exec("insert into zonkers (userid, name, wherefore) values (?, ?, ?)",
|
|
||||||
userinfo.UserID, name, wherefore)
|
|
||||||
|
|
||||||
if wherefore != "zonvoy" {
|
|
||||||
filtcache.Clear(userinfo.UserID)
|
|
||||||
}
|
|
||||||
|
|
||||||
http.Redirect(w, r, "/zonkzone", http.StatusSeeOther)
|
http.Redirect(w, r, "/zonkzone", http.StatusSeeOther)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue