SyntaxFix
Write A Post
Hire A Developer
Questions
You can simplify it to
if ($user_sam -and $user_case) { ... }
because empty strings coerce to $false (and so does $null, for that matter).
$false
$null