Added unpin logic