feat: ondersteuning voor admin_consent parameter in OAuth callback

This commit is contained in:
2026-09-08 19:37:58 +02:00
parent 3e5a23ddff
commit 97da502a8e
+7 -1
View File
@@ -59,7 +59,13 @@ if (!$stateUserId && (empty($receivedState) || empty($expectedState) || !hash_eq
exit;
}
// 3. Autorisatiecode controleren
// Afhandeling van beheerderstoestemming (Admin Consent)
if (!empty($_GET['admin_consent'])) {
header('Location: /integrations.php?success=' . urlencode('Beheerdersgoedkeuring voor uw organisatie is succesvol verleend! Klik nu op "Koppel Outlook" om uw agenda te synchroniseren.'));
exit;
}
// 5. Autorisatiecode controleren
$code = $_GET['code'] ?? '';
if (empty($code)) {
header('Location: /integrations.php?error=' . urlencode('Geen autorisatiecode ontvangen van Microsoft.'));