New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove methods returning/using EventReference
#383
Conversation
Codecov ReportPatch coverage:
Additional details and impacted files@@ Coverage Diff @@
## main #383 +/- ##
==========================================
+ Coverage 55.57% 56.01% +0.43%
==========================================
Files 44 44
Lines 6409 6356 -53
==========================================
- Hits 3562 3560 -2
+ Misses 2510 2460 -50
+ Partials 337 336 -1
☔ View full report in Codecov by Sentry. |
…7evink/eventreference
event_builder.go
Outdated
// Since gomatrixserverlib otherwise deals with EventReferences, | ||
// take the event IDs out of these and replace the prev_events and | ||
// auth_events with those new arrays. | ||
switch prevEvents := eventStruct.PrevEvents.(type) { | ||
case []string: | ||
eventStruct.PrevEvents = prevEvents | ||
case []EventReference: | ||
case []eventReference: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we need this? I thought EventFormatV2 == strings only, so this case should never be hit?
event_builder.go
Outdated
|
||
// Base64FromEventID returns, if possible, the base64bytes representation | ||
// of the given eventID. Returns an empty spec.Base64Bytes if an error occurs decoding. | ||
func base64FromEventID(eventID string) spec.Base64Bytes { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Call this eventHashFromEventID
as that is more accurate.
Companion PR to matrix-org/gomatrixserverlib#383
Also removes
CacheCost
which is now implemented in Dendrite.