Removing messy code in login filter init