} else if (listObj.isEmpty()) {
                throw new IllegalPathOperationException(String.format(
                        "Unable to remove path '%s', as array is empty.",
                        pathElement.getPath(currentPath, false)
                ));