adds community contribution for CiscoUCS connection fix (#63)
All checks were successful
continuous-integration/drone/push Build is passing

#### 📖 Summary

- relates to #53

#### 📑 Test Plan

> 💡 Select your test plan for the code changes.

- [x] Tested via Drone.io pipeline
- [ ] Custom test
- [ ] No test plan

##### Details / Justification

<!-- Add your test details or justification for missing tests here. -->

#### 📚 Additional Notes

<!-- A place for additional detail notes. -->

Co-authored-by: OCram85 <marco.blessing@googlemail.com>
Reviewed-on: #63
This commit is contained in:
OCram85 2022-07-15 11:25:11 +02:00
parent 3d90d912ee
commit a66e8249db

View File

@ -177,7 +177,7 @@ function Connect-To {
switch ($Type) { switch ($Type) {
"CiscoUcs" { "CiscoUcs" {
try { try {
$handle = Connect-Ucs -Name $RemoteHost -Credential $creds -ErrorAction Stop $handle = Connect-Ucs -Name $RemoteHost -Credential $creds -ErrorAction 'Stop' -NotDefault
$ExecutionContext.SessionState.PSVariable.Set('DefaultUcs', $handle) $ExecutionContext.SessionState.PSVariable.Set('DefaultUcs', $handle)
} }