This commit fixes a bug where $_, which should only reference the caught error object within catch blocks, was incorrectly used in Stop-Function calls outside of catch blocks. This could lead to unexpected behavior as $_ would incorrectly refer to the current object in the pipeline rather than the intended error object. The Stop-Function calls have been updated to remove the erroneous reference to ensure error handling behaves as expected.
PRs from repos that have not been recently reforked or recloned will be closed and @potatoqualitee will cherry-pick your commits and open a new PR with your changes.
[x] Please confirm you have the smaller repo (85MB .git directory vs 275MB or 110MB or 185MB .git directory)
This commit fixes a bug where
$_
, which should only reference the caught error object withincatch
blocks, was incorrectly used inStop-Function
calls outside ofcatch
blocks. This could lead to unexpected behavior as$_
would incorrectly refer to the current object in the pipeline rather than the intended error object. TheStop-Function
calls have been updated to remove the erroneous reference to ensure error handling behaves as expected.Please read -- recent changes to our repo
On November 10, 2022, we removed some bloat from our repository (for the second and final time). This change requires that all contributors reclone or refork their repo.
PRs from repos that have not been recently reforked or recloned will be closed and @potatoqualitee will cherry-pick your commits and open a new PR with your changes.
Type of Change
.\tests\manual.pester.ps1
)