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 {
165
165
}
166
166
167
167
# 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.
169
169
# 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' )) {
172
172
# Output the step
173
173
$stepOutput
174
174
# and set the output turtle to false.
175
175
$outputTurtle = $false
176
- } else {
176
+ } elseif ( $null -ne $stepOutput ) {
177
177
# Set the current turtle to the step output.
178
178
$currentTurtle = $stepOutput
179
179
# and output it later (presumably).
180
- $outputTurtle = $true
180
+ $outputTurtle = $true
181
181
}
182
182
}
183
183
You can’t perform that action at this time.
0 commit comments