added listeners for changes