addition of new dashboard
This commit is contained in:
18
backend/modules/auth/single.js
Normal file
18
backend/modules/auth/single.js
Normal file
@@ -0,0 +1,18 @@
|
||||
import { checkUser } from "../../http/auth.js";
|
||||
import { getConfig } from "../../common/config.js";
|
||||
|
||||
const key = 'single';
|
||||
|
||||
export function getModuleConfig() {
|
||||
const config = getConfig();
|
||||
return {
|
||||
core: process.env.SINGLE_API_KEY_CORE,
|
||||
archive: process.env.SINGLE_API_KEY_ARCHIVE,
|
||||
}
|
||||
}
|
||||
|
||||
export async function initModule(app, passport) {
|
||||
if (process.env.SINGLE_API_KEY_CORE && process.env.SINGLE_API_KEY_ARCHIVE) {
|
||||
await checkUser(key, 'https://single', 'single', 'single');
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user