mirror of
https://github.com/DeNNiiInc/dbgate.git
synced 2026-04-28 23:26:00 +00:00
fix - community app should not check license
This commit is contained in:
@@ -2,6 +2,7 @@ import { apiCall, enableApi, getAuthCategory } from './utility/api';
|
|||||||
import { getConfig } from './utility/metadataLoaders';
|
import { getConfig } from './utility/metadataLoaders';
|
||||||
import { isAdminPage } from './utility/pageDefs';
|
import { isAdminPage } from './utility/pageDefs';
|
||||||
import getElectron from './utility/getElectron';
|
import getElectron from './utility/getElectron';
|
||||||
|
import { isProApp } from './utility/proTools';
|
||||||
|
|
||||||
export function isOauthCallback() {
|
export function isOauthCallback() {
|
||||||
const params = new URLSearchParams(location.search);
|
const params = new URLSearchParams(location.search);
|
||||||
@@ -127,6 +128,9 @@ export async function handleAuthOnStartup(config) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function checkInvalidLicense() {
|
function checkInvalidLicense() {
|
||||||
|
if (!isProApp()) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
if (!config.isLicenseValid) {
|
if (!config.isLicenseValid) {
|
||||||
if (config.storageDatabase || getElectron()) {
|
if (config.storageDatabase || getElectron()) {
|
||||||
if (isAdminPage()) {
|
if (isAdminPage()) {
|
||||||
@@ -142,6 +146,9 @@ export async function handleAuthOnStartup(config) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function checkTrialDaysLeft() {
|
function checkTrialDaysLeft() {
|
||||||
|
if (!isProApp()) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
if (
|
if (
|
||||||
config.trialDaysLeft != null &&
|
config.trialDaysLeft != null &&
|
||||||
config.trialDaysLeft <= 14 &&
|
config.trialDaysLeft <= 14 &&
|
||||||
|
|||||||
Reference in New Issue
Block a user