mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-10-15 15:02:20 +00:00
Merged HEAD (5.1) to 5.1.N (5.1.1)
115803 mgardner: ACE-4317 parse emailed potential dbid as a long before using as a solr query parameter git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/BRANCHES/DEV/5.1.N/root@115808 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -456,13 +456,17 @@ public class EmailServiceImpl implements EmailService
|
|||||||
ResultSet resultSet = null;
|
ResultSet resultSet = null;
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
String query = "@sys\\:node-dbid:" + parts[0];
|
Long nodeId = Long.parseLong(parts[0]);
|
||||||
|
String query = "@sys\\:node-dbid:" + nodeId;
|
||||||
resultSet = searchService.query(storeRef, SearchService.LANGUAGE_LUCENE, query);
|
resultSet = searchService.query(storeRef, SearchService.LANGUAGE_LUCENE, query);
|
||||||
if (resultSet.length() > 0)
|
if (resultSet.length() > 0)
|
||||||
{
|
{
|
||||||
return resultSet.getNodeRef(0);
|
return resultSet.getNodeRef(0);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
catch (NumberFormatException e)
|
||||||
|
{
|
||||||
|
}
|
||||||
finally
|
finally
|
||||||
{
|
{
|
||||||
if(resultSet != null)
|
if(resultSet != null)
|
||||||
@@ -470,6 +474,7 @@ public class EmailServiceImpl implements EmailService
|
|||||||
resultSet.close();
|
resultSet.close();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
throw new EmailMessageException(ERR_INVALID_NODE_ADDRESS, recipient);
|
throw new EmailMessageException(ERR_INVALID_NODE_ADDRESS, recipient);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user