From a6b48620fdd343fa7088a8b5f5a69ce8ab102eba Mon Sep 17 00:00:00 2001 From: laanwj <126646+laanwj@users.noreply.github.com> Date: Fri, 27 Sep 2024 13:38:32 +0200 Subject: [PATCH] fix: sqlite schema comment `event_hash` is the raw SHA256 hash of the event, not 4-byte hash. --- src/repo/sqlite_migration.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/repo/sqlite_migration.rs b/src/repo/sqlite_migration.rs index 0000801..5fadc1e 100644 --- a/src/repo/sqlite_migration.rs +++ b/src/repo/sqlite_migration.rs @@ -40,7 +40,7 @@ PRAGMA user_version = {}; -- Event Table CREATE TABLE IF NOT EXISTS event ( id INTEGER PRIMARY KEY, -event_hash BLOB NOT NULL, -- 4-byte hash +event_hash BLOB NOT NULL, -- 32-byte SHA256 hash first_seen INTEGER NOT NULL, -- when the event was first seen (not authored!) (seconds since 1970) created_at INTEGER NOT NULL, -- when the event was authored expires_at INTEGER, -- when the event expires and may be deleted