Added lock to permalink if entry/post was published