added locks to data things