From 4bb8a5e0e65443cac24bef52bc519735c11a6907 Mon Sep 17 00:00:00 2001 From: spaced4ndy <8711996+spaced4ndy@users.noreply.github.com> Date: Thu, 1 Oct 2026 18:18:44 +0400 Subject: [PATCH] explain the nullable store receipt columns --- .../Postgres/Migrations/M20260925_badge_store_receipts.hs | 3 +++ .../Store/SQLite/Migrations/M20260925_badge_store_receipts.hs | 3 +++ 2 files changed, 6 insertions(+) diff --git a/src/Simplex/Chat/Store/Postgres/Migrations/M20260925_badge_store_receipts.hs b/src/Simplex/Chat/Store/Postgres/Migrations/M20260925_badge_store_receipts.hs index 9051146fcb..de14f2676b 100644 --- a/src/Simplex/Chat/Store/Postgres/Migrations/M20260925_badge_store_receipts.hs +++ b/src/Simplex/Chat/Store/Postgres/Migrations/M20260925_badge_store_receipts.hs @@ -6,6 +6,9 @@ module Simplex.Chat.Store.Postgres.Migrations.M20260925_badge_store_receipts whe import Data.Text (Text) import Text.RawString.QQ (r) +-- | invoice_id is null for a receipt this install did not start — a reinstall, a restored database, or the +-- same store account on another device. provider and transaction_ref are null until a receipt arrives, and +-- distinct NULLs let several rows await one at once. m20260925_badge_store_receipts :: Text m20260925_badge_store_receipts = [r| diff --git a/src/Simplex/Chat/Store/SQLite/Migrations/M20260925_badge_store_receipts.hs b/src/Simplex/Chat/Store/SQLite/Migrations/M20260925_badge_store_receipts.hs index b215bcab93..7a92cdb514 100644 --- a/src/Simplex/Chat/Store/SQLite/Migrations/M20260925_badge_store_receipts.hs +++ b/src/Simplex/Chat/Store/SQLite/Migrations/M20260925_badge_store_receipts.hs @@ -5,6 +5,9 @@ module Simplex.Chat.Store.SQLite.Migrations.M20260925_badge_store_receipts where import Database.SQLite.Simple (Query) import Database.SQLite.Simple.QQ (sql) +-- | invoice_id is null for a receipt this install did not start — a reinstall, a restored database, or the +-- same store account on another device. provider and transaction_ref are null until a receipt arrives, and +-- distinct NULLs let several rows await one at once. m20260925_badge_store_receipts :: Query m20260925_badge_store_receipts = [sql|