Skip to content

Fix for transalted guyides#23

Merged
MrHinsh merged 1 commit intomainfrom
fix-for-trasalted-lists
Jan 19, 2026
Merged

Fix for transalted guyides#23
MrHinsh merged 1 commit intomainfrom
fix-for-trasalted-lists

Conversation

@MrHinsh
Copy link
Member

@MrHinsh MrHinsh commented Jan 19, 2026

Summary by CodeRabbit

  • Bug Fixes
    • Improved guide content detection to more accurately determine content availability and page status.

✏️ Tip: You can customize this high-level summary in your review settings.

Copilot AI review requested due to automatic review settings January 19, 2026 17:52
@MrHinsh MrHinsh enabled auto-merge January 19, 2026 17:52
@coderabbitai
Copy link

coderabbitai bot commented Jan 19, 2026

Walkthrough

The change replaces content existence validation in guide version page logic, shifting from Page.Content to Page.Plain and Page.WordCount checks. This affects how the system determines whether a guide version has substantive content for display status purposes.

Changes

Cohort / File(s) Summary
Content Detection Logic
module/layouts/_partials/functions/get-guide-translations-for-version.html
Replaces Page.Content dependency with Page.Plain trimmed validation and WordCount > 0 requirement for content presence detection; updates ReadOnline/Status determination logic accordingly

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Poem

Plain words speak louder than content's deceit,
Count the substance, trim the empty seat—
A pragmatic check, precise and true,
Status flows where real words grew. 📝✨

🚥 Pre-merge checks | ✅ 2 | ❌ 1
❌ Failed checks (1 inconclusive)
Check name Status Explanation Resolution
Title check ❓ Inconclusive The title contains multiple typos ('transalted' instead of 'translated', 'guyides' instead of 'guides') and is vague about what specifically was fixed for translated guides. Correct the spelling to 'Fix for translated guides' or be more specific about what aspect of translated guides was fixed, e.g., 'Fix translated guide version detection' based on the actual content change.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch fix-for-trasalted-lists

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

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

Copy link

Copilot AI left a comment

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 fixes the logic for detecting whether translated guide pages have actual content. The previous implementation checked only the HTML content, while the new implementation uses a more robust approach by checking both word count and plain text content.

Changes:

  • Improved content detection logic to check $page.WordCount and $page.Plain instead of just $page.Content
  • Updated the comment to accurately reflect the new checking method

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Merged via the queue into main with commit 9806362 Jan 19, 2026
11 of 12 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.

1 participant