fixed a mixup between login and index pages