|
@@ -227,10 +227,15 @@ export function showSharedVideoButton(): Function {
|
227
|
227
|
export function showSIPCallButton(show: boolean): Function {
|
228
|
228
|
return (dispatch: Dispatch<*>) => {
|
229
|
229
|
const buttonName = 'sip';
|
|
230
|
+
|
|
231
|
+ // hide the button if there is a config to check for user roles,
|
|
232
|
+ // based on the token and the the user is guest
|
230
|
233
|
const shouldShow
|
231
|
234
|
= APP.conference.sipGatewayEnabled()
|
232
|
235
|
&& UIUtil.isButtonEnabled(buttonName)
|
233
|
|
- && show;
|
|
236
|
+ && show
|
|
237
|
+ && (!config.enableUserRolesBasedOnToken
|
|
238
|
+ || !APP.tokenData.isGuest);
|
234
|
239
|
|
235
|
240
|
if (shouldShow) {
|
236
|
241
|
dispatch(setToolbarButton(buttonName, {
|