Fix input nodes not being config nodes

Although I'm not sure whether they are supposed to be called config
nodes, netconf-cli depends on them being "config: true".

Change-Id: I2c5cba9b59f74fd5a85c70b3bde0c3217f71bda3
Issue: https://tree.taiga.io/project/jktjkt-netconf-cli/issue/232
Depends-on: https://gerrit.cesnet.cz/c/CzechLight/dependencies/+/5606
diff --git a/src/yang_schema.cpp b/src/yang_schema.cpp
index 5a31a49..1dc05db 100644
--- a/src/yang_schema.cpp
+++ b/src/yang_schema.cpp
@@ -500,6 +500,10 @@
 bool YangSchema::isConfig(const std::string& path) const
 {
     auto node = getSchemaNode(path.c_str());
+    if (node->isInput()) {
+        return true;
+    }
+
     try {
         if (node->config() == libyang::Config::True) {
             return true;
diff --git a/tests/yang.cpp b/tests/yang.cpp
index 2560f64..0ba0af8 100644
--- a/tests/yang.cpp
+++ b/tests/yang.cpp
@@ -1188,6 +1188,7 @@
         SECTION("isConfig")
         {
             REQUIRE(ys.isConfig("/example-schema:leafInt32"));
+            REQUIRE(ys.isConfig("/example-schema:rpcOneInput/ahoj"));
             REQUIRE_FALSE(ys.isConfig("/example-schema:clockSpeed"));
             REQUIRE_FALSE(ys.isConfig("/example-schema:systemStats"));
             REQUIRE_FALSE(ys.isConfig("/example-schema:systemStats/upTime"));