fix possible rare bug with incorrect replacement of '/' in base64 string