Bug fixes for detail view.