when you are not on shore power are you sure that plug is actually live and connected to the rest of your system?
It would seem real unsafe(and odd) if your shore power connection was actually hot when you are on battery..
I suspect..and do NOT know.. that your inverter/charger would have a relay that has disconnected that shore power connector from anything when on battery.
You could get out your multimeter and check things out if you are comfortable doing that sort of thing. It is always a good idea to know which, if any, of your electrical equipment is bonding neutral to ground or not.