Could you tell us your GPA with the B and then with the W?
Personally I don't think a B is a bad grade, and it's certainly not something I would cover up with a W. I'm also wondering why they would even do this, it sounds incredibly sketchy. A "W" is usually given when a person withdraws from a course later in a semester, not something they would give after you'd already finished and received a grade for. Do you mean a "P", for a "pass"?
I still regret taking my 3rd Japanese course as Pass/Fail instead of taking the grade, I found out from my professor that it would've been a B. When you take a "P", or withdraw with a "W", anyone reading it would likely assume you were going to receive a very very low grade (I'd say C- or below). That's just my take.