Fix bug in BM