started implementing locks