avoid Encoding::CompatibilityError when logging multipart post in debug mode
close #294