removed redundant variable
added Pin lock type