Browse Source

fix(support-url): Hide contact support button when SUPPORT_URL is empty

- fix issue on error notification on invite contacts
j8
hmuresan 3 years ago
parent
commit
17f77a4246

+ 4
- 7
react/features/invite/components/add-people-dialog/web/InviteContactsForm.js View File

@@ -511,11 +511,7 @@ class InviteContactsForm extends AbstractAddPeopleDialog<Props, State> {
511 511
         const supportString = t('inlineDialogFailure.supportMsg');
512 512
         const supportLink = interfaceConfig.SUPPORT_URL;
513 513
 
514
-        if (!supportLink) {
515
-            return null;
516
-        }
517
-
518
-        const supportLinkContent = (
514
+        const supportLinkContent = supportLink ? (
519 515
             <span>
520 516
                 <span>
521 517
                     { supportString.padEnd(supportString.length + 1) }
@@ -524,13 +520,14 @@ class InviteContactsForm extends AbstractAddPeopleDialog<Props, State> {
524 520
                     <a
525 521
                         aria-label = { supportLink }
526 522
                         href = { supportLink }
527
-                        rel = 'noopener noreferrer'>
523
+                        rel = 'noopener noreferrer'
524
+                        target = '_blank'>
528 525
                         { t('inlineDialogFailure.support') }
529 526
                     </a>
530 527
                 </span>
531 528
                 <span>.</span>
532 529
             </span>
533
-        );
530
+        ) : null;
534 531
 
535 532
         return (
536 533
             <div className = 'modal-dialog-form-error'>

+ 1
- 1
react/features/notifications/components/web/Notification.js View File

@@ -116,7 +116,7 @@ class Notification extends AbstractNotification<Props> {
116 116
                 }
117 117
             ];
118 118
 
119
-            if (!hideErrorSupportLink) {
119
+            if (!hideErrorSupportLink && interfaceConfig.SUPPORT_URL) {
120 120
                 buttons.push({
121 121
                     content: this.props.t('dialog.contactSupport'),
122 122
                     onClick: this._onOpenSupportLink

Loading…
Cancel
Save