} else if (item.getRevision().getNumber() < 0) {
SVNErrorMessage err = SVNErrorMessage.create(SVNErrorCode.CLIENT_BAD_REVISION, "Commit item ''{0}'' has copy flag but an invalid revision", item.getFile());
SVNErrorManager.error(err);
}
}
SVNEvent event = null;
boolean closeDir = false;
if (item.isAdded() && item.isDeleted()) {
event = SVNEventFactory.createCommitEvent(wcAccess.getAnchor(), item.getFile(), SVNEventAction.COMMIT_REPLACED, item.getKind(), null);
} else if (item.isAdded()) {
String mimeType = null;
if (item.getKind() == SVNNodeKind.FILE) {
SVNAdminArea dir = item.getWCAccess().retrieve(item.getFile().getParentFile());
mimeType = dir.getProperties(item.getFile().getName()).getPropertyValue(SVNProperty.MIME_TYPE);
}
event = SVNEventFactory.createCommitEvent(wcAccess.getAnchor(), item.getFile(), SVNEventAction.COMMIT_ADDED, item.getKind(), mimeType);
} else if (item.isDeleted()) {
event = SVNEventFactory.createCommitEvent(wcAccess.getAnchor(), item.getFile(), SVNEventAction.COMMIT_DELETED, item.getKind(), null);
} else if (item.isContentsModified() || item.isPropertiesModified()) {
event = SVNEventFactory.createCommitEvent(wcAccess.getAnchor(), item.getFile(), SVNEventAction.COMMIT_MODIFIED, item.getKind());
}
if (event != null) {
event.setPath(item.getPath());
wcAccess.handleEvent(event, ISVNEventHandler.UNKNOWN);
}
long rev = item.getRevision().getNumber();
long cfRev = item.getCopyFromRevision().getNumber();//item.getCopyFromURL() != null ? rev : -1;
if (item.isDeleted()) {