Below is a link for the proper type of device that is installed in the bilge as original equipment from the builders or a proper replacement and hard wired in to the a/c electrical panel to a breaker that should be labeled something like "battery charger".
The type of charger you have is more typically used in open air areas as the others have indicated.
Are you able to follow that romex back to a source where it gets it's power from?
The main issue is that if you have that charger plugged in to a/c, go to start the engine and had some type of gas fumes and a spark emitted from those exposed outlets.....well, might not be good.
I remember a couple years ago hearing two "old salts" as they were walking by on the dock talking and one mentioned he'll never start his boat again while plugged into a/c as that caused some major electrical problem.
I figured I'm just going to learn from that and follow the same practice.......but in your case with that exposed a/c outlet, it would be even more reason to have no a/c connected when firing up.
While you're underway that charger won't be plugged into a/c so no chance of a spark; I'm figuring you don't have a generator installed or would be using that while underway.
Products :: Battery Chargers :: Flyback 20-3 12 Volt
So what I would suggest is to obtain and install a properly wired bilge charger/converter but until you can do that, just make sure those connections stay covered and don't start the boat with live a/c to that outlet or the charger plugged in.
BTW: an inverter is a device that takes 12v d.c. and converts to 120 a/c; you've got a converter/charger going from a/c to d/c.
Mark