Fixes for BoW.