Fix duplicate in error message 69/103769/2
authorIvan Hrasko <ivan.hrasko@pantheon.tech>
Mon, 12 Dec 2022 08:46:47 +0000 (09:46 +0100)
committerRobert Varga <robert.varga@pantheon.tech>
Thu, 29 Dec 2022 21:39:33 +0000 (22:39 +0100)
Fix duplicate occurrence of yang-ext:mount in error message
when operation is not found.

JIRA: NETCONF-926
Change-Id: I2d8f9f1e2f1c4257e3802f7e2df983597f34c6c4
Signed-off-by: Ivan Hrasko <ivan.hrasko@pantheon.tech>
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit 8de9afa5d61cc863e216a98d39a950bb300514d0)

restconf/restconf-nb-rfc8040/src/main/java/org/opendaylight/restconf/nb/rfc8040/rests/services/impl/RestconfOperationsServiceImpl.java

index dfa708274b17faa6431ad0a6bb9c889fb49b6130..e418e7521d6c74ae1ad9a54d312cc8f561b74f15 100644 (file)
@@ -69,8 +69,7 @@ public class RestconfOperationsServiceImpl implements RestconfOperationsService
             final String errMsg = "URI has bad format. If operations behind mount point should be showed, URI has to "
                     + " end with " + RestconfConstants.MOUNT;
             LOG.debug("{} for {}", errMsg, identifier);
-            throw new RestconfDocumentedException(errMsg + RestconfConstants.MOUNT, ErrorType.PROTOCOL,
-                    ErrorTag.INVALID_VALUE);
+            throw new RestconfDocumentedException(errMsg, ErrorType.PROTOCOL, ErrorTag.INVALID_VALUE);
         }
 
         final InstanceIdentifierContext mountPointIdentifier = ParserIdentifier.toInstanceIdentifier(identifier,