Liking and unliking a post still gives you the first like badge. I noticed this when I was using a test account and accidentally clicking the like button and unliking it. Then, I realized that I got the badge.
Technically, you did still like a post. This may be the intended behavior.
This is totally correct as stated above.