defmodule Poxa.Event do
  def notify(event, data), do: :gen_event.sync_notify(Poxa.Event, Map.put(data, :event, event))

  def add_handler(handler, pid) do
    GenEvent.add_mon_handler(Poxa.Event, handler, pid)
  end

  def remove_handler(handler, pid) do
    GenEvent.remove_handler(Poxa.Event, handler, pid)
  end
end

defmodule Poxa.Event do
  def notify(event, data), do: GenEvent.sync_notify(Poxa.Event, Map.put(data, :event, event))

  def add_handler(handler, pid) do
    GenEvent.add_mon_handler(Poxa.Event, handler, pid)
  end

  def remove_handler(handler, pid) do
    GenEvent.remove_handler(Poxa.Event, handler, pid)
  end
end

Change Poxa.Event to use GenEvent everywhere
Change Poxa.Event to use GenEvent everywhere

It was probably due to a bug that :gen_event was being used insted of GenEvent.
There is no need for this anymore

edgurgel/poxa,edgurgel/poxa,edgurgel/poxa