mirror of
https://github.com/IT4Change/gradido.git
synced 2025-12-13 07:45:54 +00:00
remove trailing slash again, log when eopage hook was recieved
This commit is contained in:
parent
18256e02ca
commit
41ee819aba
@ -73,7 +73,7 @@ const createServer = async (context: any = serverContext): Promise<any> => {
|
||||
})
|
||||
|
||||
// Elopage Webhook
|
||||
app.post('/hook/elopage/' + CONFIG.WEBHOOK_ELOPAGE_SECRET + '/', elopageWebhook)
|
||||
app.post('/hook/elopage/' + CONFIG.WEBHOOK_ELOPAGE_SECRET, elopageWebhook)
|
||||
// Github Webhook
|
||||
if (CONFIG.WEBHOOK_GITHUB) {
|
||||
app.post(
|
||||
|
||||
@ -28,13 +28,14 @@
|
||||
*/
|
||||
|
||||
import { LoginElopageBuys } from '@entity/LoginElopageBuys'
|
||||
import { LoginUser } from '@entity/LoginUser'
|
||||
import { getCustomRepository } from 'typeorm'
|
||||
import { UserResolver } from '../graphql/resolver/UserResolver'
|
||||
import { LoginElopageBuysRepository } from '../typeorm/repository/LoginElopageBuys'
|
||||
import { LoginUserRepository } from '../typeorm/repository/LoginUser'
|
||||
|
||||
export const elopageWebhook = async (req: any, res: any): Promise<void> => {
|
||||
// eslint-disable-next-line no-console
|
||||
console.log('Elopage Hook received')
|
||||
res.status(200).end() // Responding is important
|
||||
const loginElopgaeBuyRepository = await getCustomRepository(LoginElopageBuysRepository)
|
||||
const loginElopgaeBuy = new LoginElopageBuys()
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user