Skip to content

Commit

Permalink
lint
Browse files Browse the repository at this point in the history
  • Loading branch information
federicocappelli committed Jul 2, 2024
1 parent a12f012 commit 36d8190
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,10 @@ public final class DefaultAppStoreRestoreFlow: AppStoreRestoreFlow {
private let subscriptionEndpointService: SubscriptionEndpointService
private let authEndpointService: AuthEndpointService

public init(accountManager: any AccountManager, storePurchaseManager: any StorePurchaseManager, subscriptionEndpointService: any SubscriptionEndpointService, authEndpointService: any AuthEndpointService) {
public init(accountManager: any AccountManager,
storePurchaseManager: any StorePurchaseManager,
subscriptionEndpointService: any SubscriptionEndpointService,
authEndpointService: any AuthEndpointService) {
self.accountManager = accountManager
self.storePurchaseManager = storePurchaseManager
self.subscriptionEndpointService = subscriptionEndpointService
Expand Down
2 changes: 1 addition & 1 deletion Sources/Subscription/Managers/SubscriptionManager.swift
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ public final class DefaultSubscriptionManager: SubscriptionManager {
case .success(let subscription):
isSubscriptionActive = subscription.isActive
case .failure(let error):
if case let .apiError(serviceError) = error, case let .serverError(statusCode, error) = serviceError {
if case let .apiError(serviceError) = error, case let .serverError(statusCode, _) = serviceError {
if statusCode == 401 {
// Token is no longer valid
accountManager.signOut()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
import Foundation
@testable import Subscription

/// Provides all mock needed for testing subscription initialised with positive outcomes and basic configurations. All mocks can be partially reconfigured with failures or incorrect data
/// Provides all mocks needed for testing subscription initialised with positive outcomes and basic configurations. All mocks can be partially reconfigured with failures or incorrect data
public struct SubscriptionMockFactory {

public static let email = "[email protected]"
Expand Down

0 comments on commit 36d8190

Please sign in to comment.