try fixing frontend function of model
This commit is contained in:
parent
1f1dc6a63b
commit
c2c2146ad3
@ -420,11 +420,11 @@ func (self *post) MessageID() string {
|
||||
}
|
||||
|
||||
func (self *post) Frontend() string {
|
||||
idx := strings.LastIndex(self.MessagePath, "!")
|
||||
idx := strings.LastIndex(self.MessagePath, "@")
|
||||
if idx == -1 {
|
||||
return self.MessagePath
|
||||
return "malformed"
|
||||
}
|
||||
return self.MessagePath[idx+1:]
|
||||
return self.MessagePath[idx : len(self.MessagePath)-2]
|
||||
}
|
||||
|
||||
func (self *post) Board() string {
|
||||
|
Reference in New Issue
Block a user