Skip to content

Commit

Permalink
Hotfix: Debug Conditional
Browse files Browse the repository at this point in the history
This changeset fixes and closes #45, wherein, the
`DEBUG` flag previously used now interferes with app code.

The fix is simple: rename it to something else.

- [x] Rename conditional flag in transport settings
- [ ] Bump lib version -> `0.1.2` and release
  • Loading branch information
sgammon committed Oct 17, 2018
1 parent 836d09d commit 137edb4
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions Sources/Client/Transport.swift
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ internal struct Transport {
static let config: TransportSettings = Transport.environment.config

// MARK: Configuration Profiles
#if DEBUG
#if DEBUG_BBX_CLIENT
/// Sandbox transport profile.
internal struct Sandbox: TransportSettings {
let data: DataEnvironment = .sandbox
Expand Down Expand Up @@ -95,7 +95,7 @@ internal struct Transport {


// MARK: - Singletons
#if DEBUG
#if DEBUG_BBX_CLIENT
fileprivate let __sandbox = Transport.Sandbox()
fileprivate let __staging = Transport.Staging()
#endif
Expand All @@ -115,7 +115,7 @@ internal enum TransportEnvironment {

/// Retrieve the configuration singleton for a particular transport environment.
var config: TransportSettings {
#if DEBUG
#if DEBUG_BBX_CLIENT
switch self {
case .sandbox: return __sandbox
case .staging: return __staging
Expand Down Expand Up @@ -226,7 +226,7 @@ internal struct ProductionPlatform: RPCServiceSettings {
let key: String? = nil
}

#if DEBUG
#if DEBUG_BBX_CLIENT
/// Local shop settings.
internal struct LocalShop: RPCServiceSettings {
let secure = false
Expand Down

0 comments on commit 137edb4

Please sign in to comment.