Commit 1c776d3d authored by Mickaël Guessant's avatar Mickaël Guessant

EWS: Avoid null in log message

git-svn-id: https://svn.code.sf.net/p/davmail/code/trunk@2299 3d1905a2-6b24-0410-a738-b14d5a86fcbd
parent ef32ebbb
...@@ -1466,7 +1466,8 @@ public class EwsExchangeSession extends ExchangeSession { ...@@ -1466,7 +1466,8 @@ public class EwsExchangeSession extends ExchangeSession {
String type; String type;
boolean isException; boolean isException;
protected Event(EWSMethod.Item response) { protected Event(String folderPath, EWSMethod.Item response) {
this.folderPath = folderPath;
itemId = new ItemId(response); itemId = new ItemId(response);
type = response.type; type = response.type;
...@@ -1925,7 +1926,7 @@ public class EwsExchangeSession extends ExchangeSession { ...@@ -1925,7 +1926,7 @@ public class EwsExchangeSession extends ExchangeSession {
condition, condition,
FolderQueryTraversal.SHALLOW, 0); FolderQueryTraversal.SHALLOW, 0);
for (EWSMethod.Item response : responses) { for (EWSMethod.Item response : responses) {
Event event = new Event(response); Event event = new Event(folderPath, response);
if ("Message".equals(event.type)) { if ("Message".equals(event.type)) {
// TODO: just exclude // TODO: just exclude
// need to check body // need to check body
...@@ -2034,7 +2035,7 @@ public class EwsExchangeSession extends ExchangeSession { ...@@ -2034,7 +2035,7 @@ public class EwsExchangeSession extends ExchangeSession {
|| "Task".equals(itemType) || "Task".equals(itemType)
// VTODOs appear as Messages // VTODOs appear as Messages
|| "Message".equals(itemType)) { || "Message".equals(itemType)) {
return new Event(item); return new Event(folderPath, item);
} else { } else {
throw new HttpNotFoundException(itemName + " not found in " + folderPath); throw new HttpNotFoundException(itemName + " not found in " + folderPath);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment