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

[IMPROVE] Livechat room closure endpoints #12360

Merged
merged 4 commits into from
Oct 20, 2018

Conversation

renatobecker-zz
Copy link

We have a few server methods calling the RocketChat.Livechat.closeRoom method, but the room validations were scattered among the server methods and not in the RocketChat.Livechat.closeRoom method.

This PR fixes this by centralizing the validations in the Livechat method.

@renatobecker-zz renatobecker-zz added this to the 0.71.0 milestone Oct 18, 2018
@engelgabriel engelgabriel temporarily deployed to rocket-chat-pr-12360 October 18, 2018 16:44 Inactive
@engelgabriel engelgabriel temporarily deployed to rocket-chat-pr-12360 October 19, 2018 13:27 Inactive
}

const user = Meteor.user();

if (!RocketChat.Livechat.closeRoom({ user, room, comment })) {
Copy link
Member

Choose a reason for hiding this comment

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

you cannot call closeRoom here before test bellow

Copy link
Author

Choose a reason for hiding this comment

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

@sampaiodiego, fixed.

@sampaiodiego sampaiodiego changed the title [IMPROVE] Livechat room closure [IMPROVE] Livechat room closure endpoints Oct 20, 2018
@sampaiodiego sampaiodiego merged commit b1a2bda into develop Oct 20, 2018
@sampaiodiego sampaiodiego deleted the livechat-improvements-room-closure branch October 20, 2018 19:33
@sampaiodiego sampaiodiego mentioned this pull request Oct 27, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants