mirror of
https://github.com/bitwarden/mobile
synced 2025-12-05 23:53:33 +00:00
Compare commits
2 Commits
dependabot
...
SG-816-add
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
3e9d3787d8 | ||
|
|
5b53c0c48f |
@@ -187,10 +187,8 @@ namespace Bit.App.Services
|
|||||||
Debug.WriteLine($"{TAG} Registered device with server.");
|
Debug.WriteLine($"{TAG} Registered device with server.");
|
||||||
|
|
||||||
await _stateService.Value.SetPushLastRegistrationDateAsync(DateTime.UtcNow);
|
await _stateService.Value.SetPushLastRegistrationDateAsync(DateTime.UtcNow);
|
||||||
if (deviceType == Device.Android)
|
|
||||||
{
|
await _stateService.Value.SetPushCurrentTokenAsync(token);
|
||||||
await _stateService.Value.SetPushCurrentTokenAsync(token);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
#if DEBUG
|
#if DEBUG
|
||||||
catch (ApiException apiEx)
|
catch (ApiException apiEx)
|
||||||
|
|||||||
@@ -5,10 +5,11 @@ namespace Bit.Core.Models.Request
|
|||||||
{
|
{
|
||||||
public class DeviceRequest
|
public class DeviceRequest
|
||||||
{
|
{
|
||||||
public DeviceRequest(string appId, IPlatformUtilsService platformUtilsService)
|
public DeviceRequest(string appId, string pushToken, IPlatformUtilsService platformUtilsService)
|
||||||
{
|
{
|
||||||
Type = platformUtilsService.GetDevice();
|
Type = platformUtilsService.GetDevice();
|
||||||
Name = platformUtilsService.GetDeviceString();
|
Name = platformUtilsService.GetDeviceString();
|
||||||
|
PushToken = pushToken;
|
||||||
Identifier = appId;
|
Identifier = appId;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -300,7 +300,8 @@ namespace Bit.Core.Services
|
|||||||
{
|
{
|
||||||
var storedTwoFactorToken = await _tokenService.GetTwoFactorTokenAsync(email);
|
var storedTwoFactorToken = await _tokenService.GetTwoFactorTokenAsync(email);
|
||||||
var appId = await _appIdService.GetAppIdAsync();
|
var appId = await _appIdService.GetAppIdAsync();
|
||||||
var deviceRequest = new DeviceRequest(appId, _platformUtilsService);
|
var pushToken = await _stateService.GetPushCurrentTokenAsync();
|
||||||
|
var deviceRequest = new DeviceRequest(appId, pushToken, _platformUtilsService);
|
||||||
|
|
||||||
string[] emailPassword;
|
string[] emailPassword;
|
||||||
string[] codeCodeVerifier;
|
string[] codeCodeVerifier;
|
||||||
|
|||||||
Reference in New Issue
Block a user