Skip to content

Commit 2dbc975

Browse files
authored
fix: Handle trailing slash in repo_url (#29)
Signed-off-by: Dhanus <[email protected]>
1 parent 4b5cb53 commit 2dbc975

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

main.py

+3
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,9 @@ async def get():
105105
async def post(repo_url: str, regenerate: bool = False):
106106
logging.info(f"Generating devcontainer.json for: {repo_url}")
107107

108+
# Normalize the repo_url by stripping trailing slashes
109+
repo_url = repo_url.rstrip('/')
110+
108111
try:
109112
exists, existing_record = check_url_exists(repo_url)
110113
logging.info(f"URL check result: exists={exists}, existing_record={existing_record}")

0 commit comments

Comments
 (0)