oneuptime/ApplicationScanner/worker/main.ts
Nawaz Dhandala e63f47a342
fix
2022-04-14 14:57:52 +01:00

21 lines
556 B
TypeScript
Executable File

import BackendAPI from '../Utils/api';
import ApplicationSecurity from './applicationSecurity';
export default {
runApplicationScan: async function (): void {
const securities: $TSFixMe = await BackendAPI.get(
'application/applicationSecurities'
);
if (securities && securities.length > 0) {
await Promise.all(
securities.map((security: $TSFixMe) => {
return ApplicationSecurity.scan(security);
})
);
}
return;
},
};