a buddy I work with had that happen on his phone. I took some compressed air( low psi) , blew out phone. nothing different. I took a pencil eraser and rubbed the " contacts" on the battery and phone with it to clean them , problem solved.
the contacts get crud built up on them over time where they connect to the phone and need to be cleaned. a pencil eraser has worked best for me and leaves no residue. his was a Moto 815 but it works on my LG and Samsung phones too.
when the phones had external contacts at the charger I would clean them too when they got kinda blackish at the point of contact. I have no clue how or if it needs to be done on the new internal contact ones
the United States is the land of the FREE because of the BRAVE!! Thank You to all who serve or have served and their families in the United States armed services!! Your sacrifices are NOT in vain may God continue to bless America
For God so loves YOU, He gave His only Son....John 3:16