Fix some more errors with duplicate callbacks being called, #274.