Skip to content

Restore net45 compatibility in ResizingUtil.AppendQuery to unblock Windows CI build - #16

Merged
chsword merged 2 commits into
masterfrom
copilot/fix-github-actions-job
Sep 27, 2026
Merged

chsword merged 2 commits into
masterfrom
copilot/fix-github-actions-job

Conversation

Copilot AI commented Sep 27, 2026 •

Copy link
Copy Markdown
Contributor

The failing GitHub Actions Windows build was caused by a net45 compile error in ResizingClient: string.IndexOf(char, StringComparison) is not available for that target. This PR applies a minimal compatibility fix in the URL query-separator path.

  • Root cause

    • AppendQuery used a newer IndexOf overload incompatible with net45, breaking ResizingClient compilation in the CI job.
  • Change made

    • Replaced the incompatible overload with a net45-safe check while preserving behavior (detect existing ? and choose & vs ?).
  • Scope

    • One-line production code change in source/ResizingClient/ResizingUtil.cs.
    • No API shape changes; URL formatting logic remains the same.
// before
var separator = urlWithoutFragment.IndexOf('?', StringComparison.Ordinal) >= 0 ? "&" : "?";

// after
var separator = urlWithoutFragment.IndexOf('?') >= 0 ? "&" : "?";

@chsword
chsword added this pull request to stack #17 September 27, 2026 05:29
Copilot AI changed the title [WIP] Fix failing GitHub Actions job Restore net45 compatibility in ResizingUtil.AppendQuery to unblock Windows CI build Sep 27, 2026
Copilot AI requested a review from chsword September 27, 2026 05:34
@chsword
chsword requested a lite review from Copilot September 27, 2026 05:41

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Copilot review overview

🟢 Approval recommended

The compatibility fix is minimal and preserves existing behavior.

Review effort: Lite
Findings: None

What changed in this PR

Restores net45 compatibility in ResizingUtil.AppendQuery without changing URL behavior.

Changes:

  • Replaces the unsupported IndexOf overload.
  • Preserves query-separator handling.
File Summary
source/​ResizingClient/​ResizingUtil.cs Updates AppendQuery for net45 compatibility.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@chsword
chsword marked this pull request as ready for review September 27, 2026 06:03
Base automatically changed from codex/fix-274085-41134369-79850956-2304-4181-a26f-944951529bcd to master September 27, 2026 06:05
chsword and others added 2 commits September 27, 2026 14:05
…6-2304-4181-a26f-944951529bcd

Add .NET 10 multi-targeting and CDN-style URL formatting compatibility
Co-authored-by: chsword <274085+chsword@users.noreply.github.com>
@chsword
chsword force-pushed the copilot/fix-github-actions-job branch from 282b649 to 4208b50 Compare September 27, 2026 06:05
@chsword
chsword merged commit a681189 into master Sep 27, 2026
4 checks passed
@chsword
chsword deleted the copilot/fix-github-actions-job branch September 27, 2026 06:05
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.

3 participants