Fixed loading issue for single page functions