From 7c571d3b127c1a3c604b6b4eb54cf273cd8afe69 Mon Sep 17 00:00:00 2001 From: Wilson Silva Date: Thu, 14 Mar 2024 22:03:50 +0000 Subject: [PATCH] Simplify the nullable RBS types --- sig/nostr/event.rbs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/sig/nostr/event.rbs b/sig/nostr/event.rbs index a2a8a89..fb6c12e 100644 --- a/sig/nostr/event.rbs +++ b/sig/nostr/event.rbs @@ -5,7 +5,7 @@ module Nostr attr_reader kind: Integer attr_reader tags: Array[Array[String]] attr_reader content: String - attr_accessor id: String?|nil + attr_accessor id: String? attr_accessor sig: Signature? def initialize: ( @@ -14,20 +14,20 @@ module Nostr content: String, ?created_at: Integer, ?tags: Array[Array[String]], - ?id: String|nil, + ?id: String?, ?sig: Signature? ) -> void def serialize: -> [Integer, String, Integer, Integer, Array[Array[String]], String] def to_h: -> { - id: String?|nil, + id: String?, pubkey: String, created_at: Integer, kind: Integer, tags: Array[Array[String]], content: String, - sig: String?|nil + sig: String? } def ==: (Event other) -> bool