Author: tolusha
Date: 2011-09-06 09:59:01 -0400 (Tue, 06 Sep 2011)
New Revision: 4873
Added:
jcr/branches/1.12.x/patch/1.12.11-GA/JCR-1660/
jcr/branches/1.12.x/patch/1.12.11-GA/JCR-1660/JCR-1660.patch
Log:
JCR-1660: patch proposed
Added: jcr/branches/1.12.x/patch/1.12.11-GA/JCR-1660/JCR-1660.patch
===================================================================
--- jcr/branches/1.12.x/patch/1.12.11-GA/JCR-1660/JCR-1660.patch
(rev 0)
+++ jcr/branches/1.12.x/patch/1.12.11-GA/JCR-1660/JCR-1660.patch 2011-09-06 13:59:01 UTC
(rev 4873)
@@ -0,0 +1,42 @@
+Index:
exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/ItemImpl.java
+===================================================================
+---
exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/ItemImpl.java (revision
4647)
++++
exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/ItemImpl.java (working
copy)
+@@ -410,6 +410,18 @@
+ ConstraintViolationException, RepositoryException
+ {
+
++ // Check if checked-in (versionable)
++ if (!parentNode.checkedOut())
++ {
++ throw new VersionException("Node " + parentNode.getPath() + " or
its nearest ancestor is checked-in");
++ }
++
++ // Check is locked
++ if (!parentNode.checkLocking())
++ {
++ throw new LockException("Node " + parentNode.getPath() + " is
locked ");
++ }
++
+ QPath qpath = QPath.makeChildPath(parentNode.getInternalPath(), propertyName);
+
+ int state;
+@@ -485,18 +497,6 @@
+ + locationFactory.createJCRPath(qpath).getAsString(false));
+ }
+
+- // Check if checked-in (versionable)
+- if (!parentNode.checkedOut())
+- {
+- throw new VersionException("Node " + parentNode.getPath() + " or
its nearest ancestor is checked-in");
+- }
+-
+- // Check is locked
+- if (!parentNode.checkLocking())
+- {
+- throw new LockException("Node " + parentNode.getPath() + " is
locked ");
+- }
+-
+ List<ValueData> valueDataList = new ArrayList<ValueData>();
+
+ // cast to required type if neccessary
Show replies by date