David's honest prayer shows us that the Lord loves to restore the joy of our salvation when we come to Him with a humble heart.