There are many different types of irregular heart beats. Prior to surgery it would be important to have you seen by your family doc, Internist, or Cardiologist. That is routinely done as part of your pre-op evaluation. After that information is know it can be better determined what if any risks you would have with any type of surgery.
Whenever elective surgery, or non-elective for that matter is performed we have to judge a patient's overall health status. Your surgeon should have you see your cardiologist to risk assess you. Then you and your surgeon together have to look at your risk and decide if surgery is a safe idea or not. Many patients with irregular heartbeats safely have surgery every day.