fixes from broken branch