Using to_string instead of deprecated to_binary