From 80a300b43e8f1297dd0f04baa99737bcfbef09a2 Mon Sep 17 00:00:00 2001 From: Paul Schaub Date: Wed, 5 Jul 2023 18:16:05 +0200 Subject: [PATCH] Small comments --- .../src/main/kotlin/org/pgpainless/wot/dijkstra/sq/Depth.kt | 2 +- .../kotlin/org/pgpainless/wot/dijkstra/sq/RevocationState.kt | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/wot-dijkstra/src/main/kotlin/org/pgpainless/wot/dijkstra/sq/Depth.kt b/wot-dijkstra/src/main/kotlin/org/pgpainless/wot/dijkstra/sq/Depth.kt index 8a0551ed..1b747f20 100644 --- a/wot-dijkstra/src/main/kotlin/org/pgpainless/wot/dijkstra/sq/Depth.kt +++ b/wot-dijkstra/src/main/kotlin/org/pgpainless/wot/dijkstra/sq/Depth.kt @@ -99,6 +99,6 @@ class Depth private constructor(val limit: Int?) : Comparable { } override fun hashCode(): Int { - return limit ?: 0 + return limit ?: 0 // TODO: 255? } } \ No newline at end of file diff --git a/wot-dijkstra/src/main/kotlin/org/pgpainless/wot/dijkstra/sq/RevocationState.kt b/wot-dijkstra/src/main/kotlin/org/pgpainless/wot/dijkstra/sq/RevocationState.kt index 9557a00f..b04c3dba 100644 --- a/wot-dijkstra/src/main/kotlin/org/pgpainless/wot/dijkstra/sq/RevocationState.kt +++ b/wot-dijkstra/src/main/kotlin/org/pgpainless/wot/dijkstra/sq/RevocationState.kt @@ -56,6 +56,7 @@ class RevocationState private constructor(val type: Type, val timestamp: Date?) if (referenceTime.timestamp.after(timestamp)) { return true } + // return equal return abs(referenceTime.timestamp.time / 1000 - timestamp!!.time / 1000) == 0L // less than one second diff } return false