wq misc bug fixes

Small bug fixes.