modified addSpec method in item.js, fixed error of failing to put key value pairs in map