Skip to content

refactor: eliminate duplicate branch kind normalization logic#6

Closed
Copilot wants to merge 3 commits into
copilot-review/apf-01-dsl-foundationfrom
copilot/sub-pr-2
Closed

refactor: eliminate duplicate branch kind normalization logic#6
Copilot wants to merge 3 commits into
copilot-review/apf-01-dsl-foundationfrom
copilot/sub-pr-2

Conversation

Copilot AI commented Nov 5, 2025

Copy link
Copy Markdown

Description

Addresses code review feedback to extract repeated branch kind normalization pattern. Three instances of identical conditional logic were replaced with calls to the existing normalizeBranchKind helper function.

Changes:

  • Refactored dynamicViewBranchCollection validator to use normalizeBranchKind() instead of inline ternary expressions at lines 124, 142, and 162
  • Added .gitignore patterns to prevent TypeScript build artifacts in src/ directories from being committed

Before:

const nestedKind = step.kind === 'alternate' || step.kind === 'alt'
  ? 'alternate'
  : 'parallel'

After:

const nestedKind = normalizeBranchKind(step.kind)

Checklist

  • I've thoroughly read the latest contribution guidelines.
  • I've rebased my branch onto main before creating this PR.
  • My commit messages follow conventional spec
  • I've added tests to cover my changes (if applicable).
  • I've verified that all new and existing tests have passed locally for mobile, tablet, and desktop screen sizes.
  • My change requires documentation updates.
  • I've updated the documentation accordingly.

💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

@coderabbitai

coderabbitai Bot commented Nov 5, 2025

Copy link
Copy Markdown

Important

Review skipped

Bot user detected.

To trigger a single review, invoke the @coderabbitai review command.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.


Note

Free review on us!

CodeRabbit is offering free reviews until Thu Nov 06 2025 to showcase some of the refinements we've made.

Comment @coderabbitai help to get the list of available commands and usage tips.

Copilot AI and others added 2 commits November 5, 2025 20:19
Co-authored-by: Jrakru <11872436+Jrakru@users.noreply.github.com>
Co-authored-by: Jrakru <11872436+Jrakru@users.noreply.github.com>
Copilot AI changed the title [WIP] Address feedback on alternate branch support implementation refactor: eliminate duplicate branch kind normalization logic Nov 5, 2025
Copilot AI requested a review from Jrakru November 5, 2025 20:30
@Jrakru

Jrakru commented Nov 5, 2025

Copy link
Copy Markdown
Owner

Closing in favor of consolidated feature branch PR

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