Removed extra logic in index controller