Updated double-checked locking to fix findbugs issue