handelImageTap was used for both a UITapGestureRecognizer target selector and a button control event UIControlEventTouchUpInside. I created a specific function for the control event.