Эх сурвалжийг харах

Merge pull request #727 from DD-P/do-not-reuse-log-files-comments

Add comment for DDFileLogger doNotReuseLogFiles flag
Ernesto Rivera 10 жил өмнө
parent
commit
64e863ebfa

+ 3 - 0
Classes/DDFileLogger.h

@@ -327,6 +327,9 @@ extern unsigned long long const kDDDefaultLogFilesDiskQuota;
  *   The frequency is given as an `NSTimeInterval`, which is a double that specifies the interval in seconds.
  *   Once the log file gets to be this old, it is rolled.
  *
+ * `doNotReuseLogFiles`
+ *   When set, will always create a new log file at application launch.
+ *
  * Both the `maximumFileSize` and the `rollingFrequency` are used to manage rolling.
  * Whichever occurs first will cause the log file to be rolled.
  *

+ 1 - 1
Classes/DDFileLogger.m

@@ -907,7 +907,7 @@ unsigned long long const kDDDefaultLogFilesDiskQuota   = 20 * 1024 * 1024; // 20
             // If previous log was created when app wasn't running in background, but now it is - we archive it and create
             // a new one.
             //
-            // If user has owerwritten to NSFileProtectionNone there is no neeed to create a new one.
+            // If user has overwritten to NSFileProtectionNone there is no neeed to create a new one.
 
             if (!_doNotReuseLogFiles && doesAppRunInBackground()) {
                 NSString *key = mostRecentLogFileInfo.fileAttributes[NSFileProtectionKey];