Merge pull request #13932 from overleaf/bg-managed-users-hide-reactivate-button
hide button to reactivate subscription for managed users GitOrigin-RevId: 3632c5ffdee68eb5e0aed1479f3b7ffb45e3aa4a
This commit is contained in:
+6
@@ -3,6 +3,7 @@ import { postJSON } from '../../../../infrastructure/fetch-json'
|
||||
import { reactivateSubscriptionUrl } from '../../data/subscription-url'
|
||||
import useAsync from '../../../../shared/hooks/use-async'
|
||||
import { useLocation } from '../../../../shared/hooks/use-location'
|
||||
import getMeta from '../../../../utils/meta'
|
||||
|
||||
function ReactivateSubscription() {
|
||||
const { t } = useTranslation()
|
||||
@@ -17,6 +18,11 @@ function ReactivateSubscription() {
|
||||
location.reload()
|
||||
}
|
||||
|
||||
// Don't show the button to reactivate the subscription for managed users
|
||||
if (getMeta('ol-cannot-reactivate-subscription')) {
|
||||
return null
|
||||
}
|
||||
|
||||
return (
|
||||
<button
|
||||
type="button"
|
||||
|
||||
Reference in New Issue
Block a user