fix: Normalize paths to prevent double slashes causing 404 errors (#37)#53
Open
vanmarkic wants to merge 2 commits intojacksteamdev:mainfrom
Open
Conversation
…cksteamdev#37) When querying the list_vault_files endpoint with a directory parameter containing a trailing slash (e.g., "DevOps/"), the system would generate paths with double slashes (e.g., "/vault/DevOps//"), resulting in HTTP 404 errors. This fix adds path normalization that strips trailing slashes before constructing the API path, ensuring consistent behavior regardless of whether users include trailing slashes in directory parameters. Fixes jacksteamdev#37
- Test removal of single and multiple trailing slashes - Test handling of paths without trailing slashes - Test empty and undefined directory inputs - Test nested paths with various trailing slash scenarios - Test API path construction prevents double slashes - Verify the fix for /vault//Documents/ bug
✅ Deploy Preview for superb-starlight-b5acb5 canceled.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Changes
Related Issue
Fixes bug #37
🤖 Generated with Claude Code