My guess is that the issue is with your dashboard page not restricting access properly. The logout page looks correct.
Remember this line:
$LogOut->Name = "Admin";
has to match the line on your login page and your restrict access code, so that the logout page works with the login page.