diff --git a/source/java/org/alfresco/filesys/smb/server/repo/ContentNetworkFile.java b/source/java/org/alfresco/filesys/smb/server/repo/ContentNetworkFile.java index c5dd6c3783..86c17659e3 100644 --- a/source/java/org/alfresco/filesys/smb/server/repo/ContentNetworkFile.java +++ b/source/java/org/alfresco/filesys/smb/server/repo/ContentNetworkFile.java @@ -300,7 +300,7 @@ public class ContentNetworkFile extends NetworkFile // ensure that the content we are going to read is valid content = FileContentReader.getSafeContentReader( (ContentReader) content, - I18NUtil.getMessage("content.content_missing"), + I18NUtil.getMessage(FileContentReader.MSG_MISSING_CONTENT), nodeRef, content); // Indicate that we only have a read-only channel to the data diff --git a/source/java/org/alfresco/repo/content/filestore/FileContentReader.java b/source/java/org/alfresco/repo/content/filestore/FileContentReader.java index 02d60f4242..a1318b64b4 100644 --- a/source/java/org/alfresco/repo/content/filestore/FileContentReader.java +++ b/source/java/org/alfresco/repo/content/filestore/FileContentReader.java @@ -43,6 +43,15 @@ import org.apache.commons.logging.LogFactory; */ public class FileContentReader extends AbstractContentReader { + /** + * message key for missing content. Parameters are + * + */ + public static final String MSG_MISSING_CONTENT = "content.content_missing"; + private static final Log logger = LogFactory.getLog(FileContentReader.class); private File file; @@ -56,7 +65,7 @@ public class FileContentReader extends AbstractContentReader * It is a convenience method that clients can use to cheaply get a reader that * is valid, regardless of whether the initial reader is valid. * - * @param existingReader a potentially valid reader + * @param existingReader a potentially invalid reader or null * @param msgTemplate the template message that will used to format the final fake content * @param args arguments to put into the fake content * @return Returns a the existing reader or a new reader onto some generated text content