mirror of
https://github.com/0ceanSlim/grain.git
synced 2024-11-21 16:17:13 +00:00
proper event structure
This commit is contained in:
parent
e2f0163bc2
commit
36956603ed
@ -10,12 +10,12 @@ import (
|
||||
)
|
||||
|
||||
type Event struct {
|
||||
ID string `json:"id"`
|
||||
PubKey string `json:"pubkey"`
|
||||
CreatedAt int64 `json:"created_at"`
|
||||
Kind int `json:"kind"`
|
||||
Content string `json:"content"`
|
||||
Tags []string `json:"tags"`
|
||||
PubKey string `json:"pubkey"`
|
||||
ID string `json:"id"`
|
||||
Content string `json:"content"`
|
||||
Sig string `json:"sig"`
|
||||
}
|
||||
|
||||
|
@ -146,7 +146,7 @@ func handleReq(ws *websocket.Conn, message []interface{}) {
|
||||
fmt.Println("Subscription added:", subID)
|
||||
|
||||
// Query the database with filters and send back the results
|
||||
events, err := QueryEvents(filters, client, "grain", "event-kind0")
|
||||
events, err := QueryEvents(filters, client, "grain", "event-kind1")
|
||||
if err != nil {
|
||||
fmt.Println("Error querying events:", err)
|
||||
return
|
||||
|
Loading…
Reference in New Issue
Block a user