Skip to content
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

No event decoration if no decryption result #7471

Merged
merged 1 commit into from
Apr 4, 2023
Merged

Conversation

Anderas
Copy link
Contributor

@Anderas Anderas commented Apr 3, 2023

There is a bug in objective-c event trust decoration, where the absence of event's decryptionDecoration (i.e. it is nil) gets evaluated to 0 in a switch statement, which happens to be a red shield. The decryptionDecoration gets set pretty quickly after local echo but it does display a brief moment where a red shield is shown, even though it shoudn't be.

To solve this add explicit `nill handling to objective-c, and also swap the order of decoration colors, so that 0 is none rather than red

@Anderas Anderas requested review from a team and stefanceriu and removed request for a team April 3, 2023 16:34
@sonarcloud
Copy link

sonarcloud bot commented Apr 3, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
No Duplication information No Duplication information

@codecov
Copy link

codecov bot commented Apr 3, 2023

Codecov Report

Patch and project coverage have no change.

Comparison is base (220fc3e) 12.29% compared to head (dfb4d7c) 12.30%.

Additional details and impacted files
@@           Coverage Diff            @@
##           develop    #7471   +/-   ##
========================================
  Coverage    12.29%   12.30%           
========================================
  Files         1645     1645           
  Lines       163147   163123   -24     
  Branches     66989    66973   -16     
========================================
  Hits         20066    20066           
+ Misses      142431   142407   -24     
  Partials       650      650           
Flag Coverage Δ
uitests 55.24% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
...les/MatrixKit/Models/Room/MXKRoomBubbleComponent.m 32.47% <ø> (+1.83%) ⬆️
...t/Views/EncryptionInfoView/MXKEncryptionInfoView.m 0.00% <ø> (ø)
Riot/Modules/Room/MXKRoomViewController.m 0.00% <ø> (ø)
Riot/Modules/Room/RoomViewController.m 0.00% <ø> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

Copy link
Contributor

@stefanceriu stefanceriu left a comment

Choose a reason for hiding this comment

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

👌

@Anderas Anderas merged commit 5334087 into develop Apr 4, 2023
9 checks passed
@Anderas Anderas deleted the andy/event_shield branch April 4, 2023 07:28
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.

None yet

2 participants