fix dependency system to correctly handle cut elements