1
0
mirror of https://github.com/bitwarden/server.git synced 2025-07-07 02:52:50 -05:00

Added support for DateTime?

This commit is contained in:
Conner Turnbull
2025-05-21 09:20:21 -04:00
parent 9596b900db
commit b56cc9231d

View File

@ -195,6 +195,13 @@ public static class LicenseExtensions
: default;
}
if (underlyingType == typeof(DateTime))
{
return DateTime.TryParse(claim.Value, out var dateTimeValue)
? (T)(object)dateTimeValue
: default;
}
if (underlyingType == typeof(DateTimeOffset))
{
return DateTimeOffset.TryParse(claim.Value, out var dateTimeOffsetValue)