downstream: fix CHATHISTORY LATEST without a bound

Fixes: 5e56cc30c5 ("downstream: fix inverted range in CHATHISTORY LATEST with a timestamp")
This commit is contained in:
Simon Ser 2022-09-16 18:55:31 +02:00
parent 5b10348957
commit bb868eae82

View file

@ -2878,7 +2878,7 @@ func (dc *downstreamConn) handleMessageRegistered(ctx context.Context, msg *irc.
var bounds [2]time.Time
bounds[0] = parseChatHistoryBound(boundsStr[0])
if subcommand == "LATEST" && boundsStr[0] == "*" {
bounds[0] = time.Now()
bounds[0] = time.Time{}
} else if bounds[0].IsZero() {
return ircError{&irc.Message{
Command: "FAIL",