summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/rabbit_peer_discovery.erl5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/rabbit_peer_discovery.erl b/src/rabbit_peer_discovery.erl
index 19df5c07cb..9c8aa90e18 100644
--- a/src/rabbit_peer_discovery.erl
+++ b/src/rabbit_peer_discovery.erl
@@ -279,7 +279,10 @@ normalize({error, Reason}) ->
-spec format_discovered_nodes(Nodes :: list()) -> string().
format_discovered_nodes(Nodes) ->
- string:join(lists:map(fun (Val) -> hd(io_lib:format("~s", [Val])) end, Nodes), ", ").
+ %% NOTE: in OTP 21 string:join/2 is deprecated but still available.
+ %% Its recommended replacement is not a drop-in one, though, so
+ %% we will not be switching just yet.
+ string:join(lists:map(fun rabbit_data_coercion:to_list/1, Nodes), ", ").