Skip to content

Fix local file serving#675

Merged
reakaleek merged 1 commit intomainfrom
feature/fix-local-file-serving
Mar 4, 2025
Merged

Fix local file serving#675
reakaleek merged 1 commit intomainfrom
feature/fix-local-file-serving

Conversation

@reakaleek
Copy link
Member

@reakaleek reakaleek commented Mar 4, 2025

Context

#666 introduced a bug where the index.md file of a directory was not found anymore.

Changes

After trying to search for a markdown file, try to find the /index.md.

Copilot AI review requested due to automatic review settings March 4, 2025 22:36
@reakaleek reakaleek self-assigned this Mar 4, 2025
@reakaleek reakaleek requested a review from a team March 4, 2025 22:36
@reakaleek reakaleek added the fix label Mar 4, 2025
Copy link
Contributor

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.

PR Overview

This pull request addresses a bug in local file serving by updating the file resolution logic.

  • Updated the initial file path determination to use Path.Combine(slug, "index.md") for directories.
  • Introduced a fallback block that adjusts the file path using slug + ".md" if the initial lookup fails.

Reviewed Changes

File Description
src/docs-builder/Http/DocumentationWebHost.cs Updated file path resolution and fallback logic for serving documentation files

Copilot reviewed 1 out of 1 changed files in this pull request and generated 1 comment.

@reakaleek reakaleek merged commit 7b20ec8 into main Mar 4, 2025
8 of 9 checks passed
@reakaleek reakaleek deleted the feature/fix-local-file-serving branch March 4, 2025 22:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants