Skip to content

Commit

Permalink
remove competitors from sitemap
Browse files Browse the repository at this point in the history
- should improve SEO of other pages
- people generally don't search for them
- all pages are very close
  • Loading branch information
brownben committed Feb 6, 2024
1 parent 34a96f7 commit 9cb2ebe
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 8 deletions.
5 changes: 1 addition & 4 deletions backend/src/routes/sitemap.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
from fastapi.responses import PlainTextResponse
from fastapi.routing import APIRouter

from ..database import Competitors, Events, LeagueClasses, Leagues
from ..database import Events, LeagueClasses, Leagues


class SitemapBuilder:
Expand Down Expand Up @@ -52,7 +52,4 @@ async def sitemap() -> str:
for event in await Events.get_all():
sitemap.add_url(f"/events/{event.id}/results")

for competitor in await Competitors.get_all():
sitemap.add_url(f"/competitors/{competitor.id}")

return sitemap.output
4 changes: 0 additions & 4 deletions backend/src/routes/tests/test_sitemap.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,6 @@
https://munroleagues.com/events/TestEvent-2022-02-03/results
https://munroleagues.com/events/TheFinalCountdown-2021-12-24/results
https://munroleagues.com/events/TestEvent-2021-12-12/results
https://munroleagues.com/competitors/1
https://munroleagues.com/competitors/2
https://munroleagues.com/competitors/3
https://munroleagues.com/competitors/4
"""


Expand Down

0 comments on commit 9cb2ebe

Please sign in to comment.