public List <UserDetails> GetUserDetails(string userId = "") { if (string.IsNullOrEmpty(userId)) { return(_userDetailAdapter.GetAllUserDetails()); } else { return(_userDetailAdapter.GetUserDetailsById(userId)); } }