Skip to content

Commit

Permalink
chore: bump up version to 0.9.3 ⬆️
Browse files Browse the repository at this point in the history
  • Loading branch information
Alex4386 committed Nov 21, 2022
1 parent 73b6b57 commit d80bbbc
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "meiling",
"version": "0.9.3-snapshot",
"version": "0.9.3",
"description": "An Opensource Next Generation \"Gatekeeper\" with oAuth2 Authentication Provider and OpenID Connect Server",
"main": "dist/",
"repository": "https://github.com/meili-NG/meiliNG",
Expand Down
4 changes: 2 additions & 2 deletions src/routes/v1/admin/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,8 @@ const adminV1Plugin = (app: FastifyInstance, opts: FastifyPluginOptions, done: (
config.node.environment === NodeEnvironment.Development
? '*'
: config?.admin?.frontend?.url
? config.admin.frontend.url
: config.frontend.url,
? config.admin.frontend.url
: config.frontend.url,
});

app.addHook('onRequest', (req, rep, next) => {
Expand Down
12 changes: 6 additions & 6 deletions src/routes/v1/admin/permissions/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,9 @@ const permissionsAdminHandler = (app: FastifyInstance, opts: FastifyPluginOption
} =
pageSize && page
? {
skip: (Number(pageSize) * (Number(page) - 1)) as number,
take: Number(pageSize) as number,
}
skip: (Number(pageSize) * (Number(page) - 1)) as number,
take: Number(pageSize) as number,
}
: {};

let prismaQuery = undefined;
Expand All @@ -45,19 +45,19 @@ const permissionsAdminHandler = (app: FastifyInstance, opts: FastifyPluginOption

const apps = await getPrismaClient().permission.findMany({
where: prismaQuery,
...paginationDetails
...paginationDetails,
});

rep.send(apps);
});

app.post('/', async (req, rep) => {
const body = req.body as { name: string; isAvailable?: boolean; };
const body = req.body as { name: string; isAvailable?: boolean };
const res = await getPrismaClient().permission.create({
data: {
name: body.name,
isAvailable: body.isAvailable,
}
},
});

rep.send(res);
Expand Down

0 comments on commit d80bbbc

Please sign in to comment.