Changed the logic to check if logout done by mobile APP
This commit is contained in:
parent
5538c3ae25
commit
f6ce8dd4f6
@ -390,8 +390,8 @@ namespace MarcoBMS.Services.Controllers
|
||||
await _refreshTokenService.BlacklistJwtTokenAsync(jwtToken);
|
||||
_logger.LogInfo("JWT access token blacklisted successfully");
|
||||
}
|
||||
string? origin = HttpContext.Request.Headers["Origin"].FirstOrDefault();
|
||||
if (string.IsNullOrWhiteSpace(origin))
|
||||
string userAgent = HttpContext.Request.Headers["User-Agent"].ToString();
|
||||
if (userAgent.Contains("Dart"))
|
||||
{
|
||||
var fcmTokenMapping = await _context.FCMTokenMappings.FirstOrDefaultAsync(ft => ft.EmployeeId == loggedInEmployee.Id && ft.TenantId == tenentId);
|
||||
if (fcmTokenMapping != null)
|
||||
|
Loading…
x
Reference in New Issue
Block a user