Skip to content

Release 2.7.2: fix endpoint support check pipeline leak#86

Merged
homotechsual merged 4 commits into
mainfrom
develop
Jun 23, 2026
Merged

Release 2.7.2: fix endpoint support check pipeline leak#86
homotechsual merged 4 commits into
mainfrom
develop

Conversation

@homotechsual

Copy link
Copy Markdown
Owner

Summary

  • Fix request wrapper functions leaking boolean return values into cmdlet output
  • Bump module version to 2.7.2
  • Add changelog entry for 2.7.2

Validation

  • Build NinjaOne (build only)
  • PSScriptAnalyzer passed during commit hook

…ipeline

- Add Out-Null pipe to Test-NinjaOneEndpointSupport calls in all request wrapper functions
- Fixes issue where cmdlets returned arrays with spurious boolean as first element
- Affected functions: New-NinjaOneGETRequest, New-NinjaOnePOSTRequest, New-NinjaOnePUTRequest, New-NinjaOnePATCHRequest, New-NinjaOneDELETERequest
Copilot AI review requested due to automatic review settings June 23, 2026 08:41
@codecov-commenter

codecov-commenter commented Jun 23, 2026

Copy link
Copy Markdown

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 18.04%. Comparing base (ff52ca2) to head (1246c90).
⚠️ Report is 149 commits behind head on main.
✅ All tests successful. No failed tests found.
❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@            Coverage Diff            @@
##            main      #86      +/-   ##
=========================================
+ Coverage   9.90%   18.04%   +8.13%     
=========================================
  Files        281      313      +32     
  Lines       3996     4256     +260     
=========================================
+ Hits         396      768     +372     
+ Misses      3600     3488     -112     
Flag Coverage Δ
core 3.50% <0.00%> (-0.23%) ⬇️
docs 0.00% <0.00%> (ø)
private 83.48% <100.00%> (+49.50%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR prepares the NinjaOne PowerShell module for release 2.7.2, primarily addressing a PowerShell output pipeline leak where endpoint support checks could emit boolean values into cmdlet output.

Changes:

  • Suppress Test-NinjaOneEndpointSupport return values in request wrapper functions by piping to Out-Null.
  • Update module manifest version to 2.7.2.
  • Add a 2.7.2 entry to CHANGELOG.md describing the fix.

Reviewed changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
Source/Private/New-NinjaOnePUTRequest.ps1 Suppresses endpoint support check output via Out-Null.
Source/Private/New-NinjaOnePOSTRequest.ps1 Suppresses endpoint support check output, but introduces a syntax error (unbalanced braces) that must be fixed.
Source/Private/New-NinjaOnePATCHRequest.ps1 Suppresses endpoint support check output, but introduces a syntax error (extra else block) that must be fixed.
Source/Private/New-NinjaOneGETRequest.ps1 Suppresses endpoint support check output via Out-Null.
Source/Private/New-NinjaOneDELETERequest.ps1 Suppresses endpoint support check output and adds type-guarding around .results/.result access.
Source/NinjaOne.psd1 Bumps ModuleVersion from 2.7.1 to 2.7.2.
CHANGELOG.md Adds a 2.7.2 changelog entry documenting the pipeline leak fix.

Comment thread Source/Private/New-NinjaOnePOSTRequest.ps1 Outdated
Comment thread Source/Private/New-NinjaOnePATCHRequest.ps1 Outdated
Comment thread Source/Private/New-NinjaOneGETRequest.ps1
Copilot AI review requested due to automatic review settings June 23, 2026 09:32
@homotechsual
homotechsual removed the request for review from Copilot June 23, 2026 09:32
@homotechsual
homotechsual merged commit 23b731d into main Jun 23, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants