The bugging of Tony Corallo's car was a case of sheer luck, in my opinion. The car was constantly guarded and was in safe places the majority of times. However, when the F.B.I decided to try to bug the car, they had to figure out how to disassemble the dashboard, put the bug in, and put everything back the correct way (and do it in record time, because had the mob guys caught anyone tampering with the car, they would have likely have been killed). On the night the F.B.I did all that, there was a huge storm and the guys watching Tony's car (he was in a meeting) went inside to stay dry. Not only did the F.B.I have to bug the car correctly, they had to cover everything with plastic in order to prevent water from leaking in, because Carallo would have knew something was up.

As for the apartment Gotti used to conduct meetings, he probably assumed that the F.B.I would never bug a civilian's home. Well, we all know that ain't the case.