mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-07-31 17:39:05 +00:00
RM-915 (The creation of a new Email Mapping: It's possible to type into "map" field any text or spaces.)
git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/modules/recordsmanagement/HEAD@55074 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -214,11 +214,11 @@ public class CustomEmailMappingServiceImpl extends AbstractLifecycleBean impleme
|
||||
*/
|
||||
public void addCustomMapping(String from, String to)
|
||||
{
|
||||
if (StringUtils.isBlank(from) || StringUtils.isBlank(to) || !getEmailMappingKeys().contains(from))
|
||||
if (StringUtils.isBlank(from) || StringUtils.isBlank(to))
|
||||
{
|
||||
throw new AlfrescoRuntimeException("Invalid values for from/to.");
|
||||
throw new AlfrescoRuntimeException("Invalid values for from/to.");
|
||||
}
|
||||
|
||||
|
||||
// create custom mapping
|
||||
CustomMapping customMapping = new CustomMapping(from, to);
|
||||
|
||||
@@ -245,6 +245,11 @@ public class CustomEmailMappingServiceImpl extends AbstractLifecycleBean impleme
|
||||
*/
|
||||
public void deleteCustomMapping(String from, String to)
|
||||
{
|
||||
if (StringUtils.isBlank(from) || StringUtils.isBlank(to))
|
||||
{
|
||||
throw new AlfrescoRuntimeException("Invalid values for from/to.");
|
||||
}
|
||||
|
||||
// create custom mapping
|
||||
CustomMapping customMapping = new CustomMapping(from, to);
|
||||
|
||||
|
Reference in New Issue
Block a user