File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -165,19 +165,19 @@ function Get-Turtle {
165165 }
166166
167167 # If the output is not a turtle object, we can output it.
168- # NOTE: This will lead to multiple types of output in the pipeline.
168+ # NOTE: This may lead to multiple types of output in the pipeline.
169169 # Luckily, this should be one of the few cases where this does not annoy too much.
170- # Properties being returned will largely be strings or numbers.
171- if (-not ($stepOutput.pstypenames -eq ' Turtle' )) {
170+ # Properties being returned will largely be strings or numbers, and these will always output directly .
171+ if ($null -ne $stepOutput -and -not ($stepOutput.pstypenames -eq ' Turtle' )) {
172172 # Output the step
173173 $stepOutput
174174 # and set the output turtle to false.
175175 $outputTurtle = $false
176- } else {
176+ } elseif ( $null -ne $stepOutput ) {
177177 # Set the current turtle to the step output.
178178 $currentTurtle = $stepOutput
179179 # and output it later (presumably).
180- $outputTurtle = $true
180+ $outputTurtle = $true
181181 }
182182 }
183183
You can’t perform that action at this time.
0 commit comments