diff --git a/source/java/org/alfresco/service/cmr/repository/ContentData.java b/source/java/org/alfresco/service/cmr/repository/ContentData.java index 98892f2fdf..59aa2201f5 100644 --- a/source/java/org/alfresco/service/cmr/repository/ContentData.java +++ b/source/java/org/alfresco/service/cmr/repository/ContentData.java @@ -25,8 +25,6 @@ package org.alfresco.service.cmr.repository; import java.io.Serializable; -import java.nio.charset.Charset; -import java.nio.charset.IllegalCharsetNameException; import java.util.Locale; import java.util.StringTokenizer; @@ -251,29 +249,6 @@ public class ContentData implements Serializable " content URL: " + contentUrl + "\n" + " mimetype: " + mimetype); } - - // Chekc that the encoding is present if the URL is present - if (encoding == null) - { - throw new IllegalArgumentException("\n" + - "The content encoding must be set whenever the URL is set: \n" + - " content URL: " + contentUrl + "\n" + - " encoding: " + encoding); - } - } - // Check the encoding - if (encoding != null) - { - try - { - Charset.forName(encoding); - } - catch (IllegalCharsetNameException e) - { - throw new IllegalArgumentException("\n" + - "The content encoding is not supported by the server: \n" + - " encoding: " + encoding); - } } }