Преглед изворни кода

user seats (#3028)

Co-authored-by: Trevor Shim <trevorshim@Trevors-Air.lan>
sunguroku пре 3 година
родитељ
комит
32aa70a578
1 измењених фајлова са 15 додато и 14 уклоњено
  1. 15 14
      dashboard/src/main/home/project-settings/InviteList.tsx

+ 15 - 14
dashboard/src/main/home/project-settings/InviteList.tsx

@@ -378,20 +378,21 @@ const InvitePage: React.FunctionComponent<Props> = ({}) => {
   }, [invites, currentProject?.id, window?.location?.host, isHTTPS, user?.id]);
 
   const hasSeats = useMemo(() => {
-    if (String(edition) === "dev-ee") {
-      return true;
-    }
-
-    if (!hasBillingEnabled) {
-      return true;
-    }
-
-    if (usage?.limit.users === 0) {
-      // If usage limit is 0, the project has unlimited seats. Otherwise, check
-      // the usage limit against the current usage.
-      return true;
-    }
-    return usage?.current.users < usage?.limit.users;
+    // if (String(edition) === "dev-ee") {
+    //   return true;
+    // }
+
+    // if (!hasBillingEnabled) {
+    //   return true;
+    // }
+
+    // if (usage?.limit.users === 0) {
+    //   // If usage limit is 0, the project has unlimited seats. Otherwise, check
+    //   // the usage limit against the current usage.
+    //   return true;
+    // }
+    // return usage?.current.users < usage?.limit.users;
+    return true;
   }, [hasBillingEnabled, usage, edition]);
 
   if (hasBillingEnabled === null && usage === null) {