Skip to content

Commit

Permalink
downloadHandler is null on DELETE methods.
Browse files Browse the repository at this point in the history
Found this bug when I was trying to delete a friend.  It deleted just fine but then threw a null exception and stopped all execution.

Turns out www.downloadHandler wasn't available when the method is DELETE .  I'm not sure if this is intentional, but this should fix it.
  • Loading branch information
hasbean authored and novabyte committed Oct 28, 2019
1 parent 3939e1e commit cd1caf2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Assets/Nakama/UnityWebRequestAdapter.cs
Original file line number Diff line number Diff line change
Expand Up @@ -127,8 +127,8 @@ private static IEnumerator SendRequest(UnityWebRequest www, Action<string> callb
}
else
{
callback?.Invoke(www.downloadHandler.text);
callback?.Invoke(www.downloadHandler?.text);
}
}
}
}
}

0 comments on commit cd1caf2

Please sign in to comment.