Skip to content

armgit / ente

Public Imported from GitHub
0

πŸ’š End-to-end encrypted cloud for everything.

Change payment check

Neeraj Guptabbe30459c98f
diff --git a/server/pkg/controller/user/userauth.go b/server/pkg/controller/user/userauth.go
index 619320262f..a4fa37e035 100644
--- a/server/pkg/controller/user/userauth.go
+++ b/server/pkg/controller/user/userauth.go
@@ -362,11 +362,7 @@ func (c *UserController) ensureLockerPaidAccess(userID int64, app ente.App) erro
return nil
}
const restrictionMsg = "locker is restricted to paid users currently"
- if c.BillingController == nil {
- log.Error("locker access: billing controller is not configured")
- return stacktrace.Propagate(ente.ErrLockerRegistrationDisabled, restrictionMsg)
- }
- if err := c.BillingController.IsActivePayingSubscriber(userID); err != nil {
+ if err := c.BillingController.HasActiveSelfOrFamilySubscription(userID, true); err != nil {
if !errors.Is(err, ente.ErrNoActiveSubscription) && !errors.Is(err, ente.ErrSharingDisabledForFreeAccounts) {
log.WithError(err).Error("locker access: failed to verify active subscription status")
}