@treeseed/sdk 0.10.8 → 0.10.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -198,15 +198,6 @@ class D1AuthStore {
|
|
|
198
198
|
}
|
|
199
199
|
async seedCatalog() {
|
|
200
200
|
const createdAt = isoNow();
|
|
201
|
-
const seeded = await this.first(
|
|
202
|
-
`SELECT key FROM permissions WHERE key = '*:*:*' LIMIT 1`
|
|
203
|
-
);
|
|
204
|
-
const adminRole = await this.first(
|
|
205
|
-
`SELECT key FROM roles WHERE key = 'platform_admin' LIMIT 1`
|
|
206
|
-
);
|
|
207
|
-
if (seeded?.key && adminRole?.key) {
|
|
208
|
-
return;
|
|
209
|
-
}
|
|
210
201
|
for (const permission of DEFAULT_PERMISSIONS) {
|
|
211
202
|
await this.run(
|
|
212
203
|
`INSERT OR IGNORE INTO permissions (id, key, resource, action, scope, description, created_at)
|