code: void removeINode(Block b) {
      BlockInfo info = blocks.get(b);
      if (info != null) {
        info.inode = null;
        if (info.getDatanode(0) == null) {  // no datanodes left
          removeBlockFromMap(b); // remove block from the map
        }
      }
    }
docs: Remove INode reference from block b.
  If it does not belong to any file and data-nodes,
  then remove the block from the block map.