mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-10-17 02:47:35 +00:00
Finish Netlify integration v1 full-loop
This commit is contained in:
@@ -51,7 +51,7 @@ export const getIntegrationAuthApps = async (req: Request, res: Response) => {
|
||||
let apps;
|
||||
try {
|
||||
apps = await getApps({
|
||||
integration: req.integrationAuth.integration,
|
||||
integrationAuth: req.integrationAuth,
|
||||
accessToken: req.accessToken
|
||||
});
|
||||
} catch (err) {
|
||||
|
||||
@@ -35,8 +35,15 @@ export const updateIntegration = async (req: Request, res: Response) => {
|
||||
// integration has the correct fields populated in [Integration]
|
||||
|
||||
try {
|
||||
const { app, environment, isActive, target } = req.body;
|
||||
|
||||
const {
|
||||
app,
|
||||
environment,
|
||||
isActive,
|
||||
target, // vercel-specific integration param
|
||||
context, // netlify-specific integration param
|
||||
siteId // netlify-specific integration param
|
||||
} = req.body;
|
||||
|
||||
integration = await Integration.findOneAndUpdate(
|
||||
{
|
||||
_id: req.integration._id
|
||||
@@ -45,7 +52,9 @@ export const updateIntegration = async (req: Request, res: Response) => {
|
||||
environment,
|
||||
isActive,
|
||||
app,
|
||||
target
|
||||
target,
|
||||
context,
|
||||
siteId
|
||||
},
|
||||
{
|
||||
new: true
|
||||
|
||||
Reference in New Issue
Block a user