Fixed bug when profile is empty.