Skip to content
Snippets Groups Projects
Commit af1a3422 authored by jaredhilton's avatar jaredhilton
Browse files

Make user const

parent 6af61d71
No related branches found
No related tags found
No related merge requests found
RocketChat.API.default.addRoute('info', { authRequired: false }, { RocketChat.API.default.addRoute('info', { authRequired: false }, {
get: function() { get: function() {
let user = this.getLoggedInUser(); const user = this.getLoggedInUser();
if (user && RocketChat.authz.hasRole(user._id, 'admin')) { if (user && RocketChat.authz.hasRole(user._id, 'admin')) {
return { return {
......
RocketChat.API.v1.addRoute('info', { authRequired: false }, { RocketChat.API.v1.addRoute('info', { authRequired: false }, {
get: function() { get: function() {
let user = this.getLoggedInUser(); const user = this.getLoggedInUser();
if (user && RocketChat.authz.hasRole(user._id, 'admin')) { if (user && RocketChat.authz.hasRole(user._id, 'admin')) {
return { return {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment