A drug delivery device for administering a drug is presented having a body, at least one electrical unit and a port for electrically contacting the electrical unit, an adapter for attaching an injection needle to the drug delivery device, a safety mechanism arranged to prevent contacting the electrical unit whilst an injection needle is in fluid communication with the drug delivery device and arranged to prevent establishing a fluid communication whilst the electrical unit is contactable.