Widget navigation button still visible with settings set to integration disabled

This commit is contained in:
Gil Eluard 2021-04-23 22:44:23 +02:00
parent 2ec7b84ed7
commit 7a31ea526e
2 changed files with 6 additions and 1 deletions

View file

@ -8,7 +8,7 @@ Changes to be released in next version
*
🐛 Bugfix
*
* RoomVC: Widget navigation button still visible with settings set to integration disabled (#4261).
⚠️ API Changes
*

View file

@ -4298,6 +4298,11 @@ const NSTimeInterval kResizeComposerAnimationDuration = .05;
- (NSUInteger)widgetsCount:(BOOL)includeUserWidgets
{
if (!RiotSettings.shared.roomInfoScreenShowIntegrations)
{
return 0;
}
NSUInteger widgetsCount = [[WidgetManager sharedManager] widgetsNotOfTypes:@[kWidgetTypeJitsiV1, kWidgetTypeJitsiV2]
inRoom:self.roomDataSource.room
withRoomState:self.roomDataSource.roomState].count;