move connection to outside class param