added authentication to the auto login just in case if a bad cookie was handed in