Skip to content

Commit

Permalink
chore: bump to v0.0.7.
Browse files Browse the repository at this point in the history
  • Loading branch information
kehiy committed Jan 8, 2025
1 parent f6ba9e0 commit ce3702b
Showing 1 changed file with 0 additions and 40 deletions.
40 changes: 0 additions & 40 deletions delivery/websocket/event_handler.go
Original file line number Diff line number Diff line change
Expand Up @@ -59,10 +59,6 @@ func (s *Server) handleEvent(conn *websocket.Conn, m message.Message) { //nolint

bloomCheckCmd := pipe.BFExists(qCtx, s.redis.BloomFilterName, eID[:])

// todo::: check config to enable/disable filter checks.
// whiteListCheckCmd := pipe.CFExists(qCtx, s.redis.WhiteListFilterName, pubkey)
// blackListCheckCmd := pipe.CFExists(qCtx, s.redis.BlackListFilterName, pubkey)

_, err := pipe.Exec(qCtx)
if err != nil {
logger.Error("checking bloom filter", "err", err.Error())
Expand All @@ -85,42 +81,6 @@ func (s *Server) handleEvent(conn *websocket.Conn, m message.Message) { //nolint
return
}

// notAllowedToWrite, err := blackListCheckCmd.Result()
// if err != nil {
// okm := message.MakeOK(false, msg.Event.ID, "error: internal error")
// _ = conn.WriteMessage(1, okm)

// status = serverFail

// return
// }
// if notAllowedToWrite {
// okm := message.MakeOK(false, msg.Event.ID, "blocked: pubkey is blocked, contact support for more details.")
// _ = conn.WriteMessage(1, okm)

// status = limitsFail

// return
// }

// allowedToWrite, err := whiteListCheckCmd.Result()
// if err != nil {
// okm := message.MakeOK(false, msg.Event.ID, "error: internal error")
// _ = conn.WriteMessage(1, okm)

// status = serverFail

// return
// }
// if !allowedToWrite {
// okm := message.MakeOK(false, msg.Event.ID, "restricted: not allowed to write.")
// _ = conn.WriteMessage(1, okm)

// status = limitsFail

// return
// }

client, ok := s.conns[conn]
if !ok {
_ = conn.WriteMessage(1, message.MakeOK(false,
Expand Down

0 comments on commit ce3702b

Please sign in to comment.