add callback for comment added, minor formatting changes