Date
This commit is contained in:
parent
85417acb41
commit
21ca438183
@ -36,17 +36,20 @@ internal static class HelperPhysicalAddress
|
|||||||
if (ipv4Address.StartsWith(physicalAddressConfiguration.IPV4Filter) && (collection.Count < 2 || (!isSuggestion && collection[^1] != ipv4Address)))
|
if (ipv4Address.StartsWith(physicalAddressConfiguration.IPV4Filter) && (collection.Count < 2 || (!isSuggestion && collection[^1] != ipv4Address)))
|
||||||
{
|
{
|
||||||
logger.LogInformation("");
|
logger.LogInformation("");
|
||||||
if (collection.Count == 0)
|
if (collection.Count == 2)
|
||||||
collection.Add($"block-{physicalAddress[^2..]}");
|
collection[1] = DateTime.Now.ToString("yyyy-MM-dd_HH-mm");
|
||||||
else
|
else if (collection.Count == 0)
|
||||||
logger.LogInformation(collection[0]);
|
|
||||||
if (collection.Count < 2)
|
|
||||||
collection.Add(DateTime.Now.ToString("yyyy-MM-dd_HH-mm"));
|
|
||||||
else
|
|
||||||
{
|
{
|
||||||
logger.LogInformation(collection[1]);
|
collection.Add($"block-{physicalAddress[^2..]}");
|
||||||
_ = collection.Remove(ipv4Address);
|
collection.Add(DateTime.Now.ToString("yyyy-MM-dd_HH-mm"));
|
||||||
}
|
}
|
||||||
|
if (collection.Count > 1)
|
||||||
|
{
|
||||||
|
logger.LogInformation(collection[0]);
|
||||||
|
logger.LogInformation(collection[1]);
|
||||||
|
}
|
||||||
|
if (collection.Remove(ipv4Address))
|
||||||
|
collection[1] = DateTime.Now.ToString("yyyy-MM-dd_HH-mm");
|
||||||
collection.Add(ipv4Address);
|
collection.Add(ipv4Address);
|
||||||
logger.LogInformation(ipv4Address);
|
logger.LogInformation(ipv4Address);
|
||||||
logger.LogInformation(physicalAddress);
|
logger.LogInformation(physicalAddress);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user