Moving all listeners to Init function and cleaning code