Skip to content

Restore null-conditional operator for logger in WorkspaceOperations - #62

Closed
rbuergi with Copilot wants to merge 2 commits into
importfrom
copilot/sub-pr-59-another-one
Closed

rbuergi with Copilot wants to merge 2 commits into
importfrom
copilot/sub-pr-59-another-one

Conversation

Copilot AI commented Nov 1, 2025 •

Copy link
Copy Markdown
Contributor

Addressed feedback from PR #59 regarding the removal of the null-conditional operator on logger.LogInformation() at line 205 in WorkspaceOperations.cs.

Changes

  • Restored logger?.LogInformation(...) from logger.LogInformation(...) in UpdateDataChangeRequest method

While the logger is obtained via GetRequiredService<ILoggerFactory>() (guaranteeing non-null), the null-conditional operator maintains defensive programming consistency with the original implementation.

// Before (potentially unsafe)
logger.LogInformation("Applying changes to Data Stream {Stream}", stream.StreamIdentity);

// After (defensive)
logger?.LogInformation("Applying changes to Data Stream {Stream}", stream.StreamIdentity);

💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Co-authored-by: rbuergi <6334612+rbuergi@users.noreply.github.com>
Copilot AI changed the title [WIP] Update import functionality based on review feedback Restore null-conditional operator for logger in WorkspaceOperations Nov 1, 2025
Copilot AI requested a review from rbuergi November 1, 2025 00:27
@rbuergi rbuergi closed this Nov 1, 2025
@rbuergi
rbuergi deleted the copilot/sub-pr-59-another-one branch November 3, 2025 21:51
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.

2 participants