-
Notifications
You must be signed in to change notification settings - Fork 316
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Paywalls
: added a few more logs (#2927)
Also improved logging by using `verboseLogHandler` and a new `Strings` enum.
- Loading branch information
Showing
5 changed files
with
84 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
// | ||
// Strings.swift | ||
// | ||
// | ||
// Created by Nacho Soto on 7/31/23. | ||
// | ||
|
||
import Foundation | ||
import RevenueCat | ||
|
||
// swiftlint:disable variable_name | ||
|
||
enum Strings { | ||
|
||
case found_multiple_packages_of_same_type(PackageType) | ||
case could_not_find_content_for_variable(variableName: String) | ||
|
||
case determining_whether_to_display_paywall | ||
case displaying_paywall | ||
case not_displaying_paywall | ||
|
||
} | ||
|
||
extension Strings: CustomStringConvertible { | ||
|
||
var description: String { | ||
switch self { | ||
case let .found_multiple_packages_of_same_type(type): | ||
return "Found multiple \(type) packages. Will use the first one." | ||
|
||
case let .could_not_find_content_for_variable(variableName): | ||
return "Couldn't find content for variable '\(variableName)'" | ||
|
||
case .determining_whether_to_display_paywall: | ||
return "Determining whether to display paywall" | ||
|
||
case .displaying_paywall: | ||
return "Condition met: will display paywall" | ||
|
||
case .not_displaying_paywall: | ||
return "Condition not met: will not display paywall" | ||
} | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters