Added the #requires statement

This commit is contained in:
Markus Fleschutz
2025-07-09 11:06:19 +02:00
parent acc0cbc8ff
commit d3e77308a8
8 changed files with 16 additions and 0 deletions

View File

@ -12,6 +12,8 @@
Author: Markus Fleschutz | License: CC0
#>
#requires -version 5.1
function GetCurrentUserSID { [CmdletBinding()] param()
Add-Type -AssemblyName System.DirectoryServices.AccountManagement
return ([System.DirectoryServices.AccountManagement.UserPrincipal]::Current).SID.Value