Safe but higher risk
It is still safe but does involve a higher risk of infection and wound dehiscence.
This may depend on the severity, and extent of your disease as well as the control as reflected by your a1c count. Discuss the relative risks i with both your endocrinologist and surgeon. Peri-operative management is very important.