Added listen function.