-
Notifications
You must be signed in to change notification settings - Fork 162
Refactor how we deal with user permissions. #4235
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
Conversation
…ions. This patch introduces a new RoomPowerLevelsProxy and its associated mock and adopts newer Rust APIs to make working with user power levels and permissions easier.
Generated by 🚫 Danger Swift against c053e93 |
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## develop #4235 +/- ##
========================================
Coverage 79.17% 79.17%
========================================
Files 798 798
Lines 74915 74927 +12
========================================
+ Hits 59311 59325 +14
+ Misses 15604 15602 -2
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
ElementX/Sources/Screens/KnockRequestsListScreen/KnockRequestsListScreenViewModel.swift
Show resolved
Hide resolved
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.
So silly question. Can we now include this powerLevels
struct in Rust's roomInfo
so that we don't even need to await a get on it?
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.
That way we could just use the RoomInfoProxy
from the publisher in all these screens like we do for everything else.
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.
Oh yeah, that's a really good idea. Let me see if I can push it through Rust side
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.
the PR looks good from an implementation point of view, but the mocking part is a bit confusing, I think we should narrow permission mocking only to the RoomPowerLevelsProxyMock
instrad of having this hybrid approach between the RoomProxy
and the former.
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.
LGTM
09cf0af
to
c053e93
Compare
|
This patch introduces a new RoomPowerLevelsProxy and its associated mock and adopts newer Rust APIs to make working with user power levels and permissions easier.