Node move with :replace fails
-----------------------------

                 Key: SLING-1648
                 URL: https://issues.apache.org/jira/browse/SLING-1648
             Project: Sling
          Issue Type: Bug
            Reporter: daniel parry


Following docs at 
http://sling.apache.org/site/manipulating-content-the-slingpostservlet-servletspost.html
 In trunk, Revision: 984520, steps to reproduce error:

curl -uadmin:admin -Ftitle="test" -Ftext="test" http://localhost:8080/test1
curl -uadmin:admin -Ftitle="test" -Ftext="test" http://localhost:8080/test2
curl -uadmin:admin -F":operation=move" -F:dest="/test2" 
http://localhost:8080/test1 (Not allowed to move without :replace as expected)
curl -uadmin:admin -F":operation=move" -F":replace=true" -F:dest="/test2" 
http://localhost:8080/test1 (This should work with :replace specified)

However, error encountered:

<html>
<head>
    <title>Error while processing /test1</title>
</head>
    <body>
    <h1>Error while processing /test1</h1>
    <table>
        <tbody>
            <tr>
                <td>Status</td>
                <td><div id="Status">500</div></td>
            </tr>
            <tr>
                <td>Message</td>
                <td><div id="Message">javax.jcr.PathNotFoundException: 
/test2</div></td>
            </tr>
            <tr>
                <td>Location</td>
                <td><a href="/test1" id="Location">/test1</a></td>
            </tr>
            <tr>
                <td>Parent Location</td>
                <td><a href="/" id="ParentLocation">/</a></td>
            </tr>
            <tr>
                <td>Path</td>
                <td><div id="Path">/test1</div></td>
            </tr>
            <tr>
                <td>Referer</td>
                <td><a href="" id="Referer"></a></td>
            </tr>
            <tr>
                <td>ChangeLog</td>
                <td><div id="ChangeLog"><pre></pre></div></td>
            </tr>
        </tbody>
    </table>
    <p><a href="">Go Back</a></p>
    <p><a href="/test1">Modified Resource</a></p>
    <p><a href="/">Parent of Modified Resource</a></p>
    </body>
</html>

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to