mirror of
https://github.com/snazy2000/SnipeitPS.git
synced 2025-12-13 18:02:30 +00:00
Fixed: -license_email must be string.
This commit is contained in:
parent
b23f73737a
commit
cc664e851e
2 changed files with 7 additions and 0 deletions
|
|
@ -144,6 +144,10 @@ function New-SnipeitLicense() {
|
||||||
$Values['termination_date'] = $Values['termination_date'].ToString("yyyy-MM-dd")
|
$Values['termination_date'] = $Values['termination_date'].ToString("yyyy-MM-dd")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if ($Values['license_email']) {
|
||||||
|
$Values['license_email'] = $Values['license_email'].address
|
||||||
|
}
|
||||||
|
|
||||||
$Parameters = @{
|
$Parameters = @{
|
||||||
Api = "/api/v1/licenses"
|
Api = "/api/v1/licenses"
|
||||||
Method = 'POST'
|
Method = 'POST'
|
||||||
|
|
|
||||||
|
|
@ -156,6 +156,9 @@ function Set-SnipeitLicense() {
|
||||||
$Values['termination_date'] = $Values['termination_date'].ToString("yyyy-MM-dd")
|
$Values['termination_date'] = $Values['termination_date'].ToString("yyyy-MM-dd")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if ($Values['license_email']) {
|
||||||
|
$Values['license_email'] = $Values['license_email'].address
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
process {
|
process {
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue