Base
This commit is contained in:
19
functions/private/Test-Session.ps1
Normal file
19
functions/private/Test-Session.ps1
Normal file
@@ -0,0 +1,19 @@
|
||||
function Test-Session {
|
||||
[CmdletBinding()]
|
||||
param (
|
||||
|
||||
)
|
||||
if ($script:ipamToken) {
|
||||
if ($script:ipamExpires -eq "Never") {
|
||||
return "Valid"
|
||||
} else {
|
||||
if ($script:ipamExpires -lt (Get-Date)) {
|
||||
return "Expired"
|
||||
} else {
|
||||
return "Valid"
|
||||
}
|
||||
}
|
||||
} else {
|
||||
return "NoToken"
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user