Skip to content

Commit

Permalink
Update Set-HuduAssetLayout.ps1
Browse files Browse the repository at this point in the history
Fixed Or statement in powershell Switch
  • Loading branch information
greenlighttec authored Aug 16, 2024
1 parent e0889a0 commit ad5c554
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions HuduAPI/Public/Set-HuduAssetLayout.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -105,10 +105,10 @@ function Set-HuduAssetLayout {
'dropdown' { $field.'field_type' = 'Dropdown' }
'embed' { $field.'field_type' = 'Embed' }
'phone' { $field.'field_type' = 'Phone' }
('email' -or 'copyabletext') { $field.'field_type' = 'Email' }
('assettag' -or 'assetlink') { $field.'field_type' = 'AssetTag' }
('website' -or 'link') { $field.'field_type' = 'Website' }
('password' -or 'confidentialtext') { $field.'field_type' = 'Password' }
{$_ -in 'email','copyabletext'} { $field.'field_type' = 'Email' }
{$_ -in 'assettag','assetlink'} { $field.'field_type' = 'AssetTag' }
{$_ -in 'website','link'} { $field.'field_type' = 'Website' }
{$_ -in 'password','confidentialtext'} { $field.'field_type' = 'Password' }
Default { Write-Error "Invalid field type: $($field.'field_type') found in field $($field.name)"; break }
}
}
Expand Down

0 comments on commit ad5c554

Please sign in to comment.