created prelimiary setVisibility functionality for events