CodeIssuesPull RequestsActionsSecurityInsights
✨ AI
More
Settings

Clean up backup files and consolidate database connection #3729

Merged⚡ AI-generatedSccantynz wants to mergeclaude/full-site-audit-UcapVmainopened Feb 27, 2026
ccantynzcommented Feb 27, 2026

Originally written by @ccantynz-alt on GitHub.
Imported from https://github.com/ccantynz-alt/Hibiscus-to-airport/pull/18


Summary

This PR removes numerous backup and temporary files that accumulated during development, consolidates the MongoDB connection into a single shared module, and makes minor improvements to environment configuration and component imports.

Key Changes

Cleanup & Organization:

  • Removed 100+ backup files (.bak, .bak_* timestamps) from frontend and backend
  • Removed temporary test files (backend_test.py, customer_booking_test.py, additional_test.py)
  • Removed documentation files that were superseded (BOOKARIDE_COMPLETE_HANDBOOK.md, ADMIN_LOGIN_FIX_GUIDE.md, DEPLOYMENT_STATUS.md, etc.)
  • Removed unused Next.js/TypeScript files and agent configuration files
  • Cleaned up .gitignore to properly exclude environment files

Database Connection Consolidation:

  • Created new backend/db.py module to provide a single shared MongoDB connection instance
  • Updated backend/booking_routes.py to import db from the new module instead of creating its own AsyncIOMotorClient
  • Removed duplicate MongoDB initialization code from booking_routes.py
  • Removed unused motor.motor_asyncio import

Minor Improvements:

  • Added format_date_nz to imports in booking_routes.py
  • Updated .env.example with clearer environment variable documentation
  • Updated frontend/tailwind.config.js with gold and elegant-dark color definitions
  • Removed unused AIChatbot component import from BookingPage.jsx
  • Updated agent documentation to reflect SMS-only notifications (removed WhatsApp reference)
  • Updated sitemap timestamps and various component imports

Implementation Details

The database consolidation follows the singleton pattern—all routes now import the shared db instance from backend/db.py, preventing multiple MongoClient connections and improving resource efficiency. This is a non-breaking change that maintains the same API surface while improving internal architecture.

https://claude.ai/code/session_01PyqnVrkpBzFz9BMiQfPP3t

ccantynzcommented Feb 27, 2026

Originally written by @vercel[bot] on GitHub.


The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
hibiscus-to-airport Ready Ready Preview, Comment Feb 27, 2026 11:22pm
hibiscus-to-airport-crr3 Ready Ready Preview, Comment Feb 27, 2026 11:22pm
hibiscus-to-airport1 Ready Ready Preview, Comment Feb 27, 2026 11:22pm
hibiscus-to-airport2 Ready Ready Preview, Comment Feb 27, 2026 11:22pm

Request Review

Cross-repo impact

See what breaks downstream if this PR merges.

Analyze →
⮌ Merged

This pull request was merged into main.

c comment · e edit title · m merge · a approve · r request changes · ? shortcuts