Updated removeListener to work properly

Added a line to remove the actual listener, rather than just its
reference