diff --git a/config/alfresco/templates/webscripts/org/alfresco/repository/upload/upload.post.js b/config/alfresco/templates/webscripts/org/alfresco/repository/upload/upload.post.js index 65adff8d0a..fb7979fd64 100644 --- a/config/alfresco/templates/webscripts/org/alfresco/repository/upload/upload.post.js +++ b/config/alfresco/templates/webscripts/org/alfresco/repository/upload/upload.post.js @@ -241,6 +241,12 @@ function main() updateNode.properties.content.guessMimetype(filename); updateNode.properties.content.guessEncoding(); // check it in again, with supplied version history note + + // Extract the metadata + // (The overwrite policy controls which if any parts of + // the document's properties are updated from this) + extractMetadata(updateNode); + updateNode = updateNode.checkin(description, majorVersion); if (aspects.length != 0) { @@ -253,11 +259,6 @@ function main() } } - // Extract the metadata - // (The overwrite policy controls which if any parts of - // the document's properties are updated from this) - extractMetadata(updateNode); - // Record the file details ready for generating the response model.document = updateNode; }