Fixed SpinLock issue & Formatting of lock method