Created
June 7, 2024 09:54
-
-
Save yannxou/aab83dd1363ce7b8d7929ee2be15c9f7 to your computer and use it in GitHub Desktop.
xcode disable logging in production
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
func customLog(_ category: String) -> OSLog { | |
#if DEBUG | |
return OSLog(subsystem: Bundle.main.bundleIdentifier!, category: category) | |
#else | |
return OSLog.disabled | |
#endif | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment