Bug fix for main page