mirror of
https://github.com/matrix-org/dendrite.git
synced 2025-12-20 21:33:19 -06:00
Don't store our own keys in the database
This commit is contained in:
parent
5e01375637
commit
811c2d8162
|
|
@ -147,13 +147,17 @@ func (s *ServerKeyAPI) FetchKeys(
|
|||
if res.ValidUntilTS > prev.ValidUntilTS {
|
||||
// This key is newer than the one we had so let's store
|
||||
// it in the database.
|
||||
if req.ServerName != s.Cfg.Matrix.ServerName {
|
||||
storeResults[req] = res
|
||||
}
|
||||
}
|
||||
} else {
|
||||
// We didn't already have a previous entry for this request
|
||||
// so store it in the database anyway for now.
|
||||
if req.ServerName != s.Cfg.Matrix.ServerName {
|
||||
storeResults[req] = res
|
||||
}
|
||||
}
|
||||
// Update the results map with this new result. If nothing
|
||||
// else, we can try verifying against this key.
|
||||
results[req] = res
|
||||
|
|
|
|||
Loading…
Reference in a new issue