Fixed duplicate listener bug