Skip to content

Check if event is rejected before using it for auth#421

Merged
S7evinK merged 2 commits intomainfrom
s7evink/state-resets2
Oct 24, 2023
Merged

Check if event is rejected before using it for auth#421
S7evinK merged 2 commits intomainfrom
s7evink/state-resets2

Conversation

@S7evinK
Copy link
Collaborator

@S7evinK S7evinK commented Oct 24, 2023

To be even more spec compliant, this adds a IsRejected type/function when resolving state.
(Part 2 of #419)

@codecov
Copy link

codecov bot commented Oct 24, 2023

Codecov Report

Attention: 1 lines in your changes are missing coverage. Please review.

Comparison is base (16e7431) 58.90% compared to head (213d8d9) 58.91%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #421      +/-   ##
==========================================
+ Coverage   58.90%   58.91%   +0.01%     
==========================================
  Files          51       51              
  Lines        7105     7108       +3     
==========================================
+ Hits         4185     4188       +3     
  Misses       2531     2531              
  Partials      389      389              
Files Coverage Δ
stateresolutionv2.go 89.94% <100.00%> (+0.05%) ⬆️
stateresolution.go 64.52% <0.00%> (ø)

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

conflicted, unconflicted,
authEvents []PDU,
userIDForSender spec.UserIDForSender,
isRejected IsRejected,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please rename this to isRejectedFn everywhere. I got very confused and though this was a bool which doesn't make sense.

@S7evinK S7evinK merged commit 58af9a2 into main Oct 24, 2023
@S7evinK S7evinK deleted the s7evink/state-resets2 branch October 24, 2023 12:47
S7evinK added a commit to matrix-org/dendrite that referenced this pull request Oct 25, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants