Skip to content

Commit 72c52be

Browse files
committed
Fix remaining Periphery warnings, one from unused file that is not included in the project.
1 parent 9a4fd20 commit 72c52be

File tree

4 files changed

+5
-289
lines changed

4 files changed

+5
-289
lines changed

Modules/Sources/Yosemite/PointOfSale/Coupons/PointOfSaleCouponFetchStrategy.swift

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ struct PointOfSaleDefaultCouponFetchStrategy: PointOfSaleCouponFetchStrategy {
2424
self.couponStoreMethods = couponStoreMethods
2525
}
2626

27-
public func fetchCoupons(pageNumber: Int) async throws -> PagedItems<POSItem> {
27+
func fetchCoupons(pageNumber: Int) async throws -> PagedItems<POSItem> {
2828
// Update local storage with data from the remote
2929
let hasMorePages = try await syncCouponsFromRemote(pageNumber: pageNumber)
3030
// Return all local coupons, including updated ones from the remote
@@ -35,7 +35,7 @@ struct PointOfSaleDefaultCouponFetchStrategy: PointOfSaleCouponFetchStrategy {
3535
/// fetchLocalCoupons provides an array of coupons that are stored locally
3636
/// It does not accept any sort of pagination
3737
/// Limited to default page size to match remote results
38-
public func fetchLocalCoupons() async throws -> [POSItem] {
38+
func fetchLocalCoupons() async throws -> [POSItem] {
3939
return await fetchLocalCoupons(limit: Constants.defaultPageSize)
4040
}
4141
}
@@ -66,7 +66,7 @@ extension PointOfSaleDefaultCouponFetchStrategy {
6666

6767
// MARK: - Search Coupon Strategy
6868

69-
public struct PointOfSaleSearchCouponFetchStrategy: PointOfSaleCouponFetchStrategy {
69+
struct PointOfSaleSearchCouponFetchStrategy: PointOfSaleCouponFetchStrategy {
7070
private let siteID: Int64
7171
private let couponStoreMethods: CouponStoreMethodsProtocol
7272
private let storage: StorageManagerType
@@ -89,7 +89,7 @@ public struct PointOfSaleSearchCouponFetchStrategy: PointOfSaleCouponFetchStrate
8989
self.analytics = analytics
9090
}
9191

92-
public func fetchCoupons(pageNumber: Int) async throws -> PagedItems<POSItem> {
92+
func fetchCoupons(pageNumber: Int) async throws -> PagedItems<POSItem> {
9393
let startTime = Date()
9494
try await couponStoreMethods.searchCoupons(siteID: siteID,
9595
keyword: searchTerm,
@@ -116,7 +116,7 @@ public struct PointOfSaleSearchCouponFetchStrategy: PointOfSaleCouponFetchStrate
116116
return resultsController.fetchCoupons(predicate: predicate)
117117
}
118118

119-
public func fetchLocalCoupons() async throws -> [POSItem] {
119+
func fetchLocalCoupons() async throws -> [POSItem] {
120120
// No support for returning local search results
121121
return []
122122
}

Modules/Sources/Yosemite/PointOfSale/Items/PointOfSaleItemFetchStrategyFactory.swift

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,6 @@ public protocol PointOfSaleItemFetchStrategyFactoryProtocol {
1010

1111
func searchStrategy(searchTerm: String,
1212
analytics: POSItemFetchAnalyticsTracking) -> PointOfSalePurchasableItemFetchStrategy
13-
14-
func popularStrategy(pageSize: Int) -> PointOfSalePurchasableItemFetchStrategy
1513
}
1614

1715
public final class PointOfSaleItemFetchStrategyFactory: PointOfSaleItemFetchStrategyFactoryProtocol {
@@ -69,8 +67,4 @@ public final class PointOfSaleFixedItemFetchStrategyFactory: PointOfSaleItemFetc
6967
analytics: POSItemFetchAnalyticsTracking) -> PointOfSalePurchasableItemFetchStrategy {
7068
fixedStrategy
7169
}
72-
73-
public func popularStrategy(pageSize: Int) -> PointOfSalePurchasableItemFetchStrategy {
74-
fixedStrategy
75-
}
7670
}

WooCommerce/Classes/POS/Presentation/CardReaderConnection/UI States/PointOfSaleItemListEmptyView.swift

Lines changed: 0 additions & 274 deletions
This file was deleted.

WooCommerce/Classes/POS/Utils/PreviewHelpers.swift

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -477,10 +477,6 @@ final class PointOfSaleItemFetchStrategyFactoryPreview: PointOfSaleItemFetchStra
477477
func searchStrategy(searchTerm: String, analytics: any POSItemFetchAnalyticsTracking) -> any PointOfSalePurchasableItemFetchStrategy {
478478
PointOfSalePreviewPurchasableItemFetchStrategy()
479479
}
480-
481-
func popularStrategy(pageSize: Int) -> any PointOfSalePurchasableItemFetchStrategy {
482-
PointOfSalePreviewPurchasableItemFetchStrategy()
483-
}
484480
}
485481

486482
final class POSOrderListFetchStrategyFactoryPreview: POSOrderListFetchStrategyFactoryProtocol {

0 commit comments

Comments
 (0)