diff --git a/src/App/Abstractions/Repositories/IDeviceApiRepository.cs b/src/App/Abstractions/Repositories/IDeviceApiRepository.cs index a1fa01f69..d96ce0653 100644 --- a/src/App/Abstractions/Repositories/IDeviceApiRepository.cs +++ b/src/App/Abstractions/Repositories/IDeviceApiRepository.cs @@ -8,7 +8,7 @@ namespace Bit.App.Abstractions { public interface IDeviceApiRepository : IApiRepository { - Task> PutTokenAsync(string identifier, DeviceTokenRequest request); + Task PutTokenAsync(string identifier, DeviceTokenRequest request); Task PutClearTokenAsync(string identifier); } } \ No newline at end of file diff --git a/src/App/Repositories/DeviceApiRepository.cs b/src/App/Repositories/DeviceApiRepository.cs index 453243da9..6ee6bd541 100644 --- a/src/App/Repositories/DeviceApiRepository.cs +++ b/src/App/Repositories/DeviceApiRepository.cs @@ -16,11 +16,11 @@ namespace Bit.App.Repositories protected override string ApiRoute => "devices"; - public virtual async Task> PutTokenAsync(string identifier, DeviceTokenRequest request) + public virtual async Task PutTokenAsync(string identifier, DeviceTokenRequest request) { if(!Connectivity.IsConnected) { - return HandledNotConnected(); + return HandledNotConnected(); } using(var client = new ApiHttpClient()) @@ -34,12 +34,10 @@ namespace Bit.App.Repositories var response = await client.SendAsync(requestMessage); if(!response.IsSuccessStatusCode) { - return await HandleErrorAsync(response); + return await HandleErrorAsync(response); } - var responseContent = await response.Content.ReadAsStringAsync(); - var responseObj = JsonConvert.DeserializeObject(responseContent); - return ApiResult.Success(responseObj, response.StatusCode); + return ApiResult.Success(response.StatusCode); } } diff --git a/src/App/Services/PushNotificationListener.cs b/src/App/Services/PushNotificationListener.cs index f34910341..f6d4dbd84 100644 --- a/src/App/Services/PushNotificationListener.cs +++ b/src/App/Services/PushNotificationListener.cs @@ -95,7 +95,7 @@ namespace Bit.App.Services } } - public async void OnUnregistered(DeviceType deviceType) + public void OnUnregistered(DeviceType deviceType) { Debug.WriteLine("Push Notification - Device Unnregistered"); }