Touch-ups and adding drone pipeline

This commit is contained in:
2023-05-23 15:40:31 -04:00
parent 19b6de68cf
commit f0c2c8d855
7 changed files with 342 additions and 7 deletions

View File

@@ -4,6 +4,7 @@ import { Context, Next } from 'koa';
export const errorHandler = async (ctx: Context, next: Next) => {
try {
await next();
// eslint-disable-next-line @typescript-eslint/no-explicit-any
} catch (error: any) {
ctx.status = error.statusCode || error.status || StatusCodes.INTERNAL_SERVER_ERROR;
error.status = ctx.status;

View File

@@ -3,7 +3,7 @@ import { Strategy as LocalStrategy } from 'passport-local';
import { authenticate } from '@mifi/auth-db/lib/api/authenticate';
export default new LocalStrategy(async (username: string, password: string, done: any) => {
export default new LocalStrategy(async (username, password, done) => {
const user = await authenticate(username, password);
done(null, user);
});