This commit is contained in:
@@ -28,7 +28,7 @@ module NostrManager
|
||||
client.on :message do |m|
|
||||
msg = JSON.parse(m) rescue nil
|
||||
if msg && msg[0] == "EVENT" && msg[2]
|
||||
puts "#{log_prefix} Event received: #{msg[2]["id"]}"
|
||||
Rails.logger.debug "#{log_prefix} Event received: #{msg[2]["id"]}"
|
||||
mutex.synchronize do
|
||||
event = msg[2]
|
||||
received_event.signal
|
||||
@@ -48,7 +48,7 @@ module NostrManager
|
||||
end
|
||||
end
|
||||
rescue Timeout::Error
|
||||
puts "#{log_prefix} Timeout: No event received within #{TIMEOUT} seconds"
|
||||
Rails.logger.debug "#{log_prefix} Timeout: No event received within #{TIMEOUT} seconds"
|
||||
ensure
|
||||
thread.exit
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user