Further work on wmf replacement(#31)