PR comments.
This commit is contained in:
parent
e460864091
commit
e12a03d05f
|
@ -1,12 +1,7 @@
|
||||||
import { tenancy, logging } from "@budibase/backend-core"
|
import { tenancy, logging } from "@budibase/backend-core"
|
||||||
import { plugins } from "@budibase/pro"
|
import { plugins } from "@budibase/pro"
|
||||||
import env from "../../environment"
|
|
||||||
|
|
||||||
export const run = async () => {
|
export const run = async () => {
|
||||||
// only a self hosted op
|
|
||||||
if (!env.SELF_HOSTED) {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
try {
|
try {
|
||||||
await tenancy.doInTenant(tenancy.DEFAULT_TENANT_ID, async () => {
|
await tenancy.doInTenant(tenancy.DEFAULT_TENANT_ID, async () => {
|
||||||
await plugins.checkPluginQuotas()
|
await plugins.checkPluginQuotas()
|
||||||
|
|
|
@ -70,6 +70,7 @@ export const buildMigrations = () => {
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
case MigrationName.PLUGIN_COUNT: {
|
case MigrationName.PLUGIN_COUNT: {
|
||||||
|
if (env.SELF_HOSTED) {
|
||||||
serverMigrations.push({
|
serverMigrations.push({
|
||||||
...definition,
|
...definition,
|
||||||
fn: pluginCount.run,
|
fn: pluginCount.run,
|
||||||
|
@ -79,6 +80,7 @@ export const buildMigrations = () => {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return serverMigrations
|
return serverMigrations
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue