Skip to content

Commit

Permalink
Tweaks to login process to avoid endless loop!
Browse files Browse the repository at this point in the history
  • Loading branch information
jegelstaff committed Apr 28, 2024
1 parent 6f875ca commit cf2cdbb
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion modules/formulize/application.php
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,8 @@

}
// no links in the entire menu, boot the user to the homepage. Anons will be able to login there.
if(count($allAppData)==0) {
global $xoopsUser;
if(count($allAppData)==0 AND !$xoopsUser) {
header("location: ".XOOPS_URL);
exit();
}
Expand Down
2 changes: 1 addition & 1 deletion modules/formulize/initialize.php
Original file line number Diff line number Diff line change
Expand Up @@ -307,7 +307,7 @@
print "<p>Formulize could not display a screen for you. Are you sure the specified screen exists?</p>";
}
}
} elseif(!$rendered) {
} elseif(!$rendered AND !$xoopsUser) {
// boot the user to the homepage. Anons will be able to login there.
header("location: ".XOOPS_URL);
exit();
Expand Down

0 comments on commit cf2cdbb

Please # to comment.