public async Task <ApiWhitelabelPrivateUserModel> UpdateProfileAsync(ApiUserUpdateModel userUpdateModel)
        {
            var userApi = _userApiService.GetApi(ApiPriority.UserInitiated);

            var response = await Policy
                           .Handle <WebException>()
                           .WaitAndRetryAsync
                           (
                retryCount: 5,
                sleepDurationProvider: retryAttempt => TimeSpan.FromSeconds(Math.Pow(2, retryAttempt))
                           )
                           .ExecuteAsync(async() => await userApi.UpdateProfileAsync(userUpdateModel));

            return(response?.Data);
        }
Exemple #2
0
 public ActionStatus Post(ApiUserUpdateModel model)
 {
     return Repo.SaveItem(_mapper.Map<UserModel>(model), DBActionType.Update);
 }