diff --git a/GRDB/Core/Configuration.swift b/GRDB/Core/Configuration.swift index 0dae035df..db85192f2 100644 --- a/GRDB/Core/Configuration.swift +++ b/GRDB/Core/Configuration.swift @@ -174,7 +174,7 @@ public struct Configuration { /// - note: [**🔥 EXPERIMENTAL**](https://github.com/groue/GRDB.swift/blob/master/README.md#what-are-experimental-features) /// /// The default clock is ``DefaultTransactionClock`` (which returns the - /// current date with `Date()`). + /// start date of the current transaction). /// /// For example: /// diff --git a/GRDB/Core/Database.swift b/GRDB/Core/Database.swift index c007c812d..56c7affb6 100644 --- a/GRDB/Core/Database.swift +++ b/GRDB/Core/Database.swift @@ -312,8 +312,8 @@ public final class Database: CustomStringConvertible, CustomDebugStringConvertib /// /// See for an example of usage. /// - /// Transaction dates, by default, are built from a new `Date()` instance. - /// You can override this default behavior by configuring + /// The transaction date, by default, is the start date of the current + /// transaction. You can override this default behavior by configuring /// ``Configuration/transactionClock``. public var transactionDate: Date { get throws { diff --git a/GRDB/Core/TransactionClock.swift b/GRDB/Core/TransactionClock.swift index 0e033d5d6..d878cd450 100644 --- a/GRDB/Core/TransactionClock.swift +++ b/GRDB/Core/TransactionClock.swift @@ -41,8 +41,9 @@ extension TransactionClock where Self == CustomTransactionClock { } } -/// The default clock. +/// The default transaction clock. public struct DefaultTransactionClock: TransactionClock { + /// Returns the start date of the current transaction. public func now(_ db: Database) throws -> Date { // An opportunity to fetch transaction time from the database when // SQLite supports the feature.