Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Dec 31, 2025

Addresses code quality issues identified in PR #5 review.

Changes

  • worker/seed.sql: Updated test team URL from legacy format to match isValidELTTLUrl validation pattern (elttl.interactive.co.uk/teams/view/{id})
  • worker/src/database.ts: Removed unused getAvailabilityKey import
  • worker/src/database.integration.test.ts: Removed unused afterEach import
  • worker/src/validation.test.ts:
    • Removed unused gamesPlayed variable
    • Eliminated redundant conditional checks where totalGames > 0 was always true/false
    • Made test intent explicit by using literal values instead of derived assignments
// Before: always-true condition
const totalGames = gamesPlayed + gamesScheduled; // 8
const selectionRate = totalGames > 0 
  ? Math.round((gamesScheduled / totalGames) * 100) 
  : 0;

// After: simplified
const totalGames = gamesPlayed + gamesScheduled; // 8
const selectionRate = Math.round((gamesScheduled / totalGames) * 100);

💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Co-authored-by: chamika <754909+chamika@users.noreply.github.com>
@cloudflare-workers-and-pages
Copy link

cloudflare-workers-and-pages bot commented Dec 31, 2025

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Preview URL Updated (UTC)
✅ Deployment successful!
View logs
tabletennis f022e34 Commit Preview URL

Branch Preview URL
Dec 31 2025, 12:45 AM

Co-authored-by: chamika <754909+chamika@users.noreply.github.com>
@cloudflare-workers-and-pages
Copy link

cloudflare-workers-and-pages bot commented Dec 31, 2025

Deploying tabletennis with  Cloudflare Pages  Cloudflare Pages

Latest commit: f022e34
Status: ✅  Deploy successful!
Preview URL: https://f86187e8.tabletennis.pages.dev
Branch Preview URL: https://copilot-sub-pr-5.tabletennis.pages.dev

View logs

Copilot AI changed the title [WIP] Add elttl availability tracker feature Fix review feedback: remove unused imports and redundant test conditions Dec 31, 2025
Copilot AI requested a review from chamika December 31, 2025 00:47
@chamika chamika marked this pull request as ready for review December 31, 2025 00:48
@chamika chamika merged commit 6366b65 into add-elttl-tracker Dec 31, 2025
2 checks passed
@chamika chamika deleted the copilot/sub-pr-5 branch December 31, 2025 00:49
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.

2 participants