Added sorting by name or location