The communications platform that puts data protection first.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
Rocket.Chat/apps/meteor/app/discussion/server/permissions.ts

14 lines
457 B

import { Permissions } from '@rocket.chat/models';
import { Meteor } from 'meteor/meteor';
Meteor.startup(async () => {
// Add permissions for discussion
const permissions = [
{ _id: 'start-discussion', roles: ['admin', 'user', 'guest', 'app'] },
{ _id: 'start-discussion-other-user', roles: ['admin', 'user', 'owner', 'app'] },
];
for await (const permission of permissions) {
await Permissions.create(permission._id, permission.roles);
}
});