fix: update image retrieval logic in LeaveController and adjust RabbitMQ configuration in appsettings
Some checks failed
release-dev / release-dev (push) Failing after 13s
Some checks failed
release-dev / release-dev (push) Failing after 13s
#2138
This commit is contained in:
parent
d6497a5d51
commit
d5c2c54eaa
3 changed files with 12 additions and 9 deletions
|
|
@ -552,12 +552,15 @@ namespace BMA.EHR.Domain.Middlewares
|
|||
return Guid.Empty.ToString("D");
|
||||
}
|
||||
|
||||
// Decode Base64 payload
|
||||
// Decode Base64Url payload (JWT uses Base64Url encoding, not standard Base64)
|
||||
var payload = parts[1];
|
||||
|
||||
// แปลง Base64Url เป็น Base64 ก่อน
|
||||
payload = payload.Replace('-', '+').Replace('_', '/');
|
||||
|
||||
// เพิ่ม padding ถ้าจำเป็น
|
||||
var padLength = 4 - (payload.Length % 4);
|
||||
if (padLength != 4)
|
||||
if (padLength < 4)
|
||||
{
|
||||
payload += new string('=', padLength);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue