catch again
This commit is contained in:
parent
b7c0c46555
commit
1ab0ef2cc2
1 changed files with 9 additions and 4 deletions
|
|
@ -86,6 +86,8 @@ namespace Yavsc.Helpers
|
|||
{
|
||||
JsonValue jsonDoc = null;
|
||||
|
||||
try
|
||||
{
|
||||
using (Stream streamQuery = request.GetRequestStream())
|
||||
{
|
||||
using (StreamWriter writer = new StreamWriter(streamQuery))
|
||||
|
|
@ -101,16 +103,19 @@ namespace Yavsc.Helpers
|
|||
jsonDoc = await Task.Run(() => JsonObject.Load(stream));
|
||||
}
|
||||
response.Close();
|
||||
}
|
||||
try
|
||||
{
|
||||
}
|
||||
}
|
||||
catch (WebException ex)
|
||||
{
|
||||
// TODO err logging
|
||||
Debug.Print($"Web request failed: {request.ToString()}\n" + ex.ToString());
|
||||
}
|
||||
return jsonDoc;
|
||||
catch (Exception ex)
|
||||
{
|
||||
Debug.Print($"Web request failed: {request.ToString()}\n" + ex.ToString());
|
||||
}
|
||||
|
||||
return jsonDoc;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue