Acer Nitro 5 Charging issues

Hello, I have a Acer Nitro 5 model AN515-55 I’ve been having an charger issue for a while. the charger disconnect periodically and had both power and charge light flashing. I’ve tried some solutions online to do with checking the battery and I had checked over the power cord but I don’t believe it is the power cord as if I turn the power connector (that plugs into the laptop) I can get it to charge but when I have to shift/move the laptop I either lose connection or I get the flashing lights. I believe this is a common problem for this laptop and wondering if it’s the power connector in the laptop and if its would be an easy fix to replace myself or more better if I see an professional? any advice would be greatly appreciated.