Browse Source

cast uidnumber to int

Tobias Simetsreiter 2 năm trước cách đây
mục cha
commit
4bcbe032e1
1 tập tin đã thay đổi với 1 bổ sung1 xóa
  1. 1 1
      bin/Add-LindevUser.ps1

+ 1 - 1
bin/Add-LindevUser.ps1

@@ -26,7 +26,7 @@ if (-not $userInGroup) {
 }
 
 if ($null -eq $newUser.uidNumber) {
-    $nextUid = ($users | Measure-Object -Property "uidNumber" -Maximum).Maximum + 1
+    $nextUid = [int](($users | Measure-Object -Property "uidNumber" -Maximum).Maximum + 1)
     "Setting User ID to Group $nextUid" | Out-Host
     
     Set-ADUser -Identity $newUser -add @{