修复Microsoft OAuth回调路由:自动检测code+state参数路由到callback

This commit is contained in:
ypsdf1
2026-07-17 11:15:08 +08:00
parent 65fc468ce1
commit b7c83903ca
+10 -1
View File
@@ -373,7 +373,16 @@ function completeAuthFlow($code) {
// Action处理
// ====================================================================
$action = getParam('action');
// ★ 检测Microsoft OAuth回调(带code+state,没有action参数)
$code = getParam('code');
$state = getParam('state');
if (!empty($code) && !empty($state)) {
// 自动路由到callback处理
$action = 'callback';
} else {
$action = getParam('action');
}
$db = getDb();
ensureTable($db);