Fix 500 issue with the index page