fix(server): redirect to setup page if not initialized (#7875)

This commit is contained in:
liuyi
2024-08-14 21:02:16 +08:00
committed by GitHub
parent 89537e6892
commit 57449c1530
20 changed files with 328 additions and 84 deletions
@@ -52,14 +52,14 @@ export function Auth() {
)
.then(res => res.json())
.then(
({
async ({
data: {
currentUser: { features },
},
}) => {
if (features.includes(FeatureType.Admin)) {
toast.success('Logged in successfully');
revalidate();
await revalidate();
} else {
toast.error('You are not an admin');
}