minor reformatting
simplified listener callbacks