refactor(db): replace sqlc with handwritten pgx repos

- Finish Paddle-to-Stripe billing migration; drop paddle/stripe libs
- Renumber migrations; add 00012 memberships+manage_token,
  00013 location_type_capacity
- Add tests: admin, auth, bookings customer service
- Remove graphify-out artifacts and stale env files

Authored By: TDvorak <[email protected]>

Generated with [Devin](https://devin.ai)

Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>
This commit is contained in:
Tomas DvorakandDevin committed 2026-09-17 20:21:34 +02:00
1 parent 2039669e2c
commit f2f7439050
93 files changed
+6987 -69060

No files matched your search

+8 -5
View File
@@ -25,10 +25,11 @@ type visitor struct {
}
type RateLimiter struct {
mu sync.Mutex
visitors map[string]*visitor
limit rate.Limit
burst int
mu sync.Mutex
visitors map[string]*visitor
limit rate.Limit
burst int
cleanupOnce sync.Once
}
func NewRateLimiter(limit rate.Limit, burst int) *RateLimiter {
@@ -40,7 +41,9 @@ func NewRateLimiter(limit rate.Limit, burst int) *RateLimiter {
}
func (r *RateLimiter) Middleware() gin.HandlerFunc {
go r.cleanupLoop()
r.cleanupOnce.Do(func() {
go r.cleanupLoop()
})
return func(c *gin.Context) {
ip := c.ClientIP()