PS4 Controller not charging/solution

I thought my controllers were broken and neither of them were working or charging for that matter I tried poking the hole in the back with a pin to reset but nothing was working so finally I RESET MY PS4 and kept the controller plugged in and it seemed to reset and turn back on like normal. Like this video if it helped THANKS