mirror of
https://github.com/ergochat/ergo.git
synced 2025-12-20 02:00:11 -08:00
Merge pull request #1809 from slingamn/issue1676_again.3
fix #1676, take 2
This commit is contained in:
commit
c9b54ee2b8
15 changed files with 104 additions and 127 deletions
|
|
@ -868,7 +868,7 @@ func (server *Server) setupListeners(config *Config) (err error) {
|
|||
// suitable for ListCorrespondents (i.e., this function is still used to
|
||||
// decide whether the ringbuf or mysql is authoritative about the client's
|
||||
// message history).
|
||||
func (server *Server) GetHistorySequence(providedChannel *Channel, client *Client, query string, excludeFlags history.ExcludeFlags) (channel *Channel, sequence history.Sequence, err error) {
|
||||
func (server *Server) GetHistorySequence(providedChannel *Channel, client *Client, query string) (channel *Channel, sequence history.Sequence, err error) {
|
||||
config := server.Config()
|
||||
// 4 cases: {persistent, ephemeral} x {normal, conversation}
|
||||
// with ephemeral history, target is implicit in the choice of `hist`,
|
||||
|
|
@ -946,9 +946,9 @@ func (server *Server) GetHistorySequence(providedChannel *Channel, client *Clien
|
|||
}
|
||||
|
||||
if hist != nil {
|
||||
sequence = hist.MakeSequence(correspondent, cutoff, excludeFlags)
|
||||
sequence = hist.MakeSequence(correspondent, cutoff)
|
||||
} else if target != "" {
|
||||
sequence = server.historyDB.MakeSequence(target, correspondent, cutoff, excludeFlags)
|
||||
sequence = server.historyDB.MakeSequence(target, correspondent, cutoff)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue