Self-review (cont'd)
This commit is contained in:
@@ -3,6 +3,7 @@ package user
|
||||
import (
|
||||
"errors"
|
||||
"github.com/stripe/stripe-go/v74"
|
||||
"heckel.io/ntfy/log"
|
||||
"net/netip"
|
||||
"regexp"
|
||||
"time"
|
||||
@@ -92,6 +93,14 @@ type Tier struct {
|
||||
StripePriceID string // Price ID for paid tiers (price_...)
|
||||
}
|
||||
|
||||
func (t *Tier) Context() log.Context {
|
||||
return log.Context{
|
||||
"tier_id": t.ID,
|
||||
"tier_name": t.Name,
|
||||
"stripe_price_id": t.StripePriceID,
|
||||
}
|
||||
}
|
||||
|
||||
// Subscription represents a user's topic subscription
|
||||
type Subscription struct {
|
||||
ID string `json:"id"`
|
||||
|
||||
Reference in New Issue
Block a user