Skip to content

Commit

Permalink
fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
car031 committed Jun 29, 2024
1 parent 1fe6274 commit b46116b
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -568,7 +568,7 @@ private Resource fileRenameOrMove(Resource source, Resource destination, String
transaction.setEvent(DocumentEvent.SHORTCUT_MOVED.toString());
documentManager.moveToFolder(document, folder, transaction);

if (!document.getFileName().equals(newName)) {
if (StringUtils.isNotEmpty(newName) && !document.getFileName().equals(newName)) {
documentManager.rename(document.getId(), newName, new DocumentHistory(transaction));
document = documentDAO.findById(Long.parseLong(source.getID()));
documentDAO.initialize(document);
Expand Down

0 comments on commit b46116b

Please sign in to comment.