midterm bugfix