Skip to content

Commit 7166e57

Browse files
authored
Appropriate comment to explain timestampSeconds and timestampNanos variables (#287)
The above comment explains that the timestampSeconds and timestampNanos variables are used to capture the current system time, which is then utilized to ensure uniqueness across multiple instances or restarts of the application.
1 parent 44307df commit 7166e57

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

docs/key_management.md

+1
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,7 @@ let ldkDerivationPath = try DerivationPath(path: "m/535h")
116116
let ldkChild = try bip32RootKey.derive(path: ldkDerivationPath)
117117
let ldkSeed = ldkChild.secretBytes()
118118

119+
// Retrieve the current system time for uniqueness across restarts.
119120
let timestampSeconds = UInt64(NSDate().timeIntervalSince1970)
120121
let timestampNanos = UInt32(truncating: NSNumber(value: timestampSeconds * 1000 * 1000))
121122

0 commit comments

Comments
 (0)