I am trying to convert a device token and using the following code (swift 3):
parameters["device_token"] = request.deviceToken.reduce("", {$0 + String(format: "%02X", $1)}).
However I am getting the compiler error Binary operator '+' cannot be applied to operands of type Any? and String
. What am I doing wrong here?