private AuthenticationTokenData SaveMobilePhone(MobileModel model) { ApiContext.AuthByClaim(); var user = UserManager.GetUsers(AuthContext.CurrentAccount.ID); model.MobilePhone = SmsManager.SaveMobilePhone(user, model.MobilePhone); MessageService.Send(MessageAction.UserUpdatedMobileNumber, MessageTarget.Create(user.ID), user.DisplayUserName(false, DisplayUserSettingsHelper), model.MobilePhone); return(new AuthenticationTokenData { Sms = true, PhoneNoise = SmsSender.BuildPhoneNoise(model.MobilePhone), Expires = new ApiDateTime(TenantManager, TimeZoneConverter, DateTime.UtcNow.Add(SmsKeyStorage.StoreInterval)) }); }