This is a safe guard for cases when your php script dies unexpectedly.
It's not guaranteed it will work either.
You should not depend on __destruct() to release your locks,
instead release them with $released = $this->releaseLock()A
and check $released if lock was properly released