mirror of
https://gitlab.com/soapbox-pub/ditto.git
synced 2025-12-06 11:29:46 +00:00
rename "policy" to "spec"
This commit is contained in:
parent
5e98bc65c0
commit
7715d53ad5
1 changed files with 3 additions and 3 deletions
|
|
@ -1,5 +1,5 @@
|
||||||
import { type AppController } from '@/app.ts';
|
import { type AppController } from '@/app.ts';
|
||||||
import { DEFAULT_POLICIES, policyRegistry } from "@/utils/policies.ts";
|
import { DEFAULT_POLICY_SPEC, policyRegistry } from "@/utils/policies.ts";
|
||||||
|
|
||||||
export const adminListPoliciesController: AppController = (c) => {
|
export const adminListPoliciesController: AppController = (c) => {
|
||||||
return c.json(Object.entries(policyRegistry.available)
|
return c.json(Object.entries(policyRegistry.available)
|
||||||
|
|
@ -21,6 +21,6 @@ export const adminCurrentPolicyController: AppController = async (c) => {
|
||||||
kinds: [11984]
|
kinds: [11984]
|
||||||
}]).then(events => events[0]);
|
}]).then(events => events[0]);
|
||||||
|
|
||||||
if (current) return c.json({ mode: conf.policyMode, policies: current });
|
if (current) return c.json({ mode: conf.policyMode, spec: current });
|
||||||
return c.json({ mode: conf.policyMode, policies: DEFAULT_POLICIES });
|
return c.json({ mode: conf.policyMode, spec: DEFAULT_POLICY_SPEC });
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue