fixing up loose ends