Skip to content

Commit cf84a26

Browse files
committed
style: constant factor explainer comment
1 parent 38c8b4f commit cf84a26

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

backend/pkg/commons/db/user.go

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -229,13 +229,14 @@ func GetUserInfo(ctx context.Context, userId uint64, userDbReader *sqlx.DB) (*t.
229229
return userInfo, nil
230230
}
231231

232-
func premiumLimitNetworkfactor() int64 {
232+
func premiumLimitNetworkFactor() int64 {
233+
// no network-specific premium limits atm, return constant factor
233234
return 1
234235
}
235236

236237
func GetProductSummary(ctx context.Context) (*t.ProductSummary, error) { // TODO @patrick post-beta put into db instead of hardcoding here and make it configurable
237238
freeTierProduct, err := GetFreeTierProduct(ctx)
238-
factor := premiumLimitNetworkfactor()
239+
factor := premiumLimitNetworkFactor()
239240
summary := t.ProductSummary{
240241
EffectiveBalancePerDashboardLimit: utils.EtherToWei(big.NewInt(102_000 * 32 * factor)),
241242
StripePublicKey: utils.Config.Frontend.Stripe.PublicKey,
@@ -439,7 +440,7 @@ func GetProductSummary(ctx context.Context) (*t.ProductSummary, error) { // TODO
439440
}
440441

441442
func GetFreeTierProduct(ctx context.Context) (*t.PremiumProduct, error) {
442-
factor := premiumLimitNetworkfactor()
443+
factor := premiumLimitNetworkFactor()
443444

444445
return &t.PremiumProduct{
445446
ProductName: "Free",

0 commit comments

Comments
 (0)