╭ changed ──────────────╮ │src/ui/Repo/Comment.zig│ ╰───────────────────────╯ ╭───────────╮ │← all files│ ╰───────────╯ ╭──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │125 id: []const u8, │ │126 ) !?CommentWithId { │ │127 const DB = evt.EventDB(hash_kind); │ │128 - const records_cursor = try haxy_moment.getCursor(hash.hashInt(hash_kind, evt.Comment.record_map_key)) orelse return null;│ │129 - const records = try DB.HashMap(.read_only).init(records_cursor); │ │130 - const record_cursor = try records.getCursor(hash.hashInt(hash_kind, id_bytes)) orelse return null; │ │131 - const record_map = try DB.HashMap(.read_only).init(record_cursor); │ │132 - const comment = try evt.read(evt.Comment.Record, DB, hash_kind, arena, record_map); │ │128 + const comment = (try evt.Comment.readById(DB, hash_kind, haxy_moment, arena, id_bytes)) orelse return null; │ │129 const parent_author: ?ui.Author = if (!std.mem.eql(u8, &comment.event.parent_id, &comment.event.thread_id)) blk: { │ │130 const parent_bytes = (try idBytes(&comment.event.parent_id)) orelse break :blk null; │ │135 - const parent_cursor = try records.getCursor(hash.hashInt(hash_kind, &parent_bytes)) orelse break :blk null; │ │136 - const parent_map = try DB.HashMap(.read_only).init(parent_cursor); │ │137 - const parent = try evt.read(evt.Comment.Record, DB, hash_kind, arena, parent_map); │ │131 + const parent = (try evt.Comment.readById(DB, hash_kind, haxy_moment, arena, &parent_bytes)) orelse break :blk null; │ │132 break :blk try ui.Author.initFromEmail(admin_moment, arena, parent.author_email); │ │133 } else null; │ │134 return .{ │ ╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯