this seems pretty much like what we have in the other listener maybe we can share some code?