Skip to content

[FIX] Added helper for testing if the current user matches the params#6845

Merged
engelgabriel merged 1 commit into
RocketChat:developfrom
abrom:add-user-not-from-params
May 2, 2017
Merged

[FIX] Added helper for testing if the current user matches the params#6845
engelgabriel merged 1 commit into
RocketChat:developfrom
abrom:add-user-not-from-params

Conversation

@abrom

@abrom abrom commented Apr 30, 2017

Copy link
Copy Markdown
Contributor

@RocketChat/core

  • Refactors users.getPresence to use current user param matcher
  • Modifies users.setAvatar to support username parameter

Updated users.getPresence and users.setAvatar REST APIs to use current user param helper
@engelgabriel engelgabriel requested a review from graywolf336 May 1, 2017 00:12
@engelgabriel engelgabriel added this to the 0.56.0 milestone May 1, 2017
@engelgabriel engelgabriel requested a review from rodrigok May 1, 2017 00:12

RocketChat.API.v1.addRoute('users.getPresence', { authRequired: true }, {
get() {
//BLAHHHHHHHHHH :'(

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Ahhhhhh so nice to have this removed ;)

@graywolf336 graywolf336 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thank for you for these changes, makes it all much cleaner and easier to use!

Do you mind updating the documentation to go along with this? If not, I will add it to my list and get it changed in the docs.

@engelgabriel engelgabriel merged commit 513fcfe into RocketChat:develop May 2, 2017
@abrom

abrom commented May 3, 2017

Copy link
Copy Markdown
Contributor Author

Yep no problem. I'll send through a PR

@abrom abrom deleted the add-user-not-from-params branch May 6, 2017 11:21
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.

3 participants