Use `bytesize` instead of `size` to compute the size of the payload. (This properly handles encoded strings, for which `size` returns the number of characters.)