Keep in mind that WD-40 will attract dust particles and eventually gum up your lock. It should only be used as a short-term solution.

If dirt or grime drips out of the lock, make sure you have a rag to catch any drips. Make sure you properly clean the keyhole and all moving parts.

Graphite lubricant is less likely to require follow up lubrication.

A few drops of oil should also be applied to the sliding bolt.