PR comments.

This commit is contained in:
Michael Drury 2022-09-24 16:55:22 +01:00
parent b20db4d22a
commit e3f4e744ab
2 changed files with 8 additions and 11 deletions

View File

@ -1,12 +1,7 @@
import { tenancy, logging } from "@budibase/backend-core"
import { plugins } from "@budibase/pro"
import env from "../../environment"
export const run = async () => {
// only a self hosted op
if (!env.SELF_HOSTED) {
return
}
try {
await tenancy.doInTenant(tenancy.DEFAULT_TENANT_ID, async () => {
await plugins.checkPluginQuotas()

View File

@ -70,6 +70,7 @@ export const buildMigrations = () => {
break
}
case MigrationName.PLUGIN_COUNT: {
if (env.SELF_HOSTED) {
serverMigrations.push({
...definition,
fn: pluginCount.run,
@ -79,6 +80,7 @@ export const buildMigrations = () => {
}
}
}
}
return serverMigrations
}