Skip to content

Commit d7bea16

Browse files
authored
Replace unnecessary string interpolation in log messages in STUN (#1687)
Replaced interpolated strings with plain literals in two warning log statements in STUNClientExtensions, as no variables were being inserted. This simplifies the logging code.
1 parent 6121f91 commit d7bea16

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/SIPSorcery/net/STUN/STUNClientExtensions.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ public static async Task<MediaStream> UseStun(this MediaStream mediaStream,
4949

5050
if (iceServer == null)
5151
{
52-
logger?.LogWarning($"The STUN client was unable to resolve a server to use.");
52+
logger?.LogWarning("The STUN client was unable to resolve a server to use.");
5353

5454
return mediaStream;
5555
}
@@ -67,7 +67,7 @@ public static async Task<MediaStream> UseStun(this MediaStream mediaStream,
6767
}
6868
else
6969
{
70-
logger?.LogWarning($"STUN client failed to get server reflexive RTP end point.");
70+
logger?.LogWarning("STUN client failed to get server reflexive RTP end point.");
7171
}
7272
}
7373

0 commit comments

Comments
 (0)