From 7380f7391fd8707bf05163b12f263f8a8be11430 Mon Sep 17 00:00:00 2001 From: wussler Date: Wed, 16 Jun 2021 17:24:25 +0200 Subject: [PATCH] Refactor internals of client time (#134) --- crypto/gopenpgp.go | 3 --- crypto/time.go | 1 - 2 files changed, 4 deletions(-) diff --git a/crypto/gopenpgp.go b/crypto/gopenpgp.go index 3a2759e..c20b5ec 100644 --- a/crypto/gopenpgp.go +++ b/crypto/gopenpgp.go @@ -1,13 +1,10 @@ // Package crypto provides a high-level API for common OpenPGP functionality. package crypto -import "time" - // GopenPGP is used as a "namespace" for many of the functions in this package. // It is a struct that keeps track of time skew between server and client. type GopenPGP struct { latestServerTime int64 - latestClientTime time.Time generationOffset int64 } diff --git a/crypto/time.go b/crypto/time.go index 3422698..82305a3 100644 --- a/crypto/time.go +++ b/crypto/time.go @@ -8,7 +8,6 @@ import ( func UpdateTime(newTime int64) { if newTime > pgp.latestServerTime { pgp.latestServerTime = newTime - pgp.latestClientTime = time.Now() } }