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

fix: Non team accounts should not see guest banner (WEBAPP-5438) #4633

Merged
merged 3 commits into from Sep 21, 2018

Conversation

gregor
Copy link
Contributor

@gregor gregor commented Sep 21, 2018

No description provided.

@@ -81,7 +81,8 @@ z.entity.Conversation = class Conversation {
this.is_self = ko.pureComputed(() => this.type() === z.conversation.ConversationType.SELF);

this.hasGuest = ko.pureComputed(() => {
return this.is_group() && this.participating_user_ets().some(userEntity => userEntity.isGuest());
const hasGuestUser = this.participating_user_ets().some(userEntity => userEntity.isGuest());
return hasGuestUser && this.is_group() && this.self.inTeam();
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Logical change that checks whether the self user is a team account.

ONE2ONE: 2,
REGULAR: 0,
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I have tripped over this naming many times. This makes a lot more sense.

@gregor gregor merged commit bf848d9 into dev Sep 21, 2018
@gregor gregor deleted the bug/WEBAPP-5438 branch September 21, 2018 14:42
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