How to get this door to shut properly

The door to the cupboard under my stairs is in the kitchen and it's a proper full size door in the same style as the other internal doors.It's the kind that you just pull open and it's got one of those roller ball type latches that holds it shut. But that has stopped working for some reason.Whenever I shut the door it just instantly pops open again. There's nothing in the way of it, it's just like the roller ball part isn't coming out far enough to catch on the other side. But it seems fine when I press it in with my hand.A minor issue but it's just really annoying! Any suggestions?

replace the catch. The problems with the rollerballs is that if you aren't all the way into the hole the spring will push on the ball which will turn (being a ball) and it will pop the door open.Replace it with some magnetic catches: simple to install and simple to replace if they go wrong. www.diy.com/search/results/?question=magnetic+catches