Skip to content

Commit

Permalink
GMapProvider: add Empty check for RefererUrl
Browse files Browse the repository at this point in the history
  • Loading branch information
tatsuy authored and meee1 committed Mar 7, 2023
1 parent 820ab90 commit cf28cce
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion ExtLibs/GMap.NET.Core/GMap.NET.MapProviders/GMapProvider.cs
Original file line number Diff line number Diff line change
Expand Up @@ -402,7 +402,8 @@ protected PureImage GetTileImageUsingHttp(string url)
{
request.Headers.Add("User-Agent", UserAgent);
request.Headers.Add("Accept", requestAccept);
request.Headers.Add("Referer", RefererUrl);
if (!string.IsNullOrEmpty(RefererUrl))
request.Headers.Add("Referer", RefererUrl);

MemoryStream data = Task.Run(async () =>
{
Expand Down

0 comments on commit cf28cce

Please sign in to comment.