summaryrefslogtreecommitdiffstats
path: root/openpgp/src/types
diff options
context:
space:
mode:
authorJustus Winter <justus@sequoia-pgp.org>2021-11-17 12:50:46 +0100
committerJustus Winter <justus@sequoia-pgp.org>2021-11-18 14:10:55 +0100
commitb56ea7ab07626ff37e14f0c15c6252b7627a6b72 (patch)
tree595c6a5d11b2db7e9141384a32762052440193ce /openpgp/src/types
parent991c759dd710bab903baa32dff8dc1fc18e78e3b (diff)
openpgp: Use a WASM-friendly SystemTime::now wrapper.
- Fixes #769.
Diffstat (limited to 'openpgp/src/types')
-rw-r--r--openpgp/src/types/timestamp.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/openpgp/src/types/timestamp.rs b/openpgp/src/types/timestamp.rs
index 148138fa..aa0341a5 100644
--- a/openpgp/src/types/timestamp.rs
+++ b/openpgp/src/types/timestamp.rs
@@ -124,7 +124,7 @@ impl fmt::Debug for Timestamp {
impl Timestamp {
/// Returns the current time.
pub fn now() -> Timestamp {
- SystemTime::now().try_into()
+ crate::now().try_into()
.expect("representable for the next hundred years")
}