作者 Karson

修复登录无限跳转BUG

@@ -92,7 +92,7 @@ class Backend extends Controller @@ -92,7 +92,7 @@ class Backend extends Controller
92 !defined('IS_AJAX') && define('IS_AJAX', $this->request->isAjax()); 92 !defined('IS_AJAX') && define('IS_AJAX', $this->request->isAjax());
93 93
94 // 非选项卡时重定向 94 // 非选项卡时重定向
95 - if (!IS_AJAX && !IS_ADDTABS && !IS_DIALOG && $path !== "/{$modulename}/index/index" && $controllername != 'ajax') 95 + if (!IS_AJAX && !IS_ADDTABS && !IS_DIALOG && !in_array($controllername, ['index', 'ajax']))
96 { 96 {
97 $url = $this->request->url(); 97 $url = $this->request->url();
98 $this->redirect('index/index', [], 302, ['referer' => $url]); 98 $this->redirect('index/index', [], 302, ['referer' => $url]);