hash table MAINTENANCE avoid code duplication
diff --git a/src/hash_table.c b/src/hash_table.c
index ca93d76..11ca8f3 100644
--- a/src/hash_table.c
+++ b/src/hash_table.c
@@ -83,28 +83,6 @@
 }
 
 /*
- * Bob Jenkin's one-at-a-time hash
- * http://www.burtleburtle.net/bob/hash/doobs.html
- *
- * Spooky hash is faster, but it works only for little endian architectures.
- */
-static uint32_t
-dict_hash(const char *key, size_t len)
-{
-    uint32_t hash, i;
-
-    for (hash = i = 0; i < len; ++i) {
-        hash += key[i];
-        hash += (hash << 10);
-        hash ^= (hash >> 6);
-    }
-    hash += (hash << 3);
-    hash ^= (hash >> 11);
-    hash += (hash << 15);
-    return hash;
-}
-
-/*
  * Usage:
  * - init hash to 0
  * - repeatedly call dict_hash_multi(), provide hash from the last call
@@ -130,6 +108,21 @@
     return hash;
 }
 
+/*
+ * Bob Jenkin's one-at-a-time hash
+ * http://www.burtleburtle.net/bob/hash/doobs.html
+ *
+ * Spooky hash is faster, but it works only for little endian architectures.
+ */
+uint32_t
+dict_hash(const char *key, size_t len)
+{
+    uint32_t hash;
+
+    hash = dict_hash_multi(0, key, len);
+    return dict_hash_multi(hash, NULL, len);
+}
+
 API void
 lydict_remove(struct ly_ctx *ctx, const char *value)
 {
diff --git a/src/hash_table.h b/src/hash_table.h
index 55a0158..70ec695 100644
--- a/src/hash_table.h
+++ b/src/hash_table.h
@@ -32,6 +32,11 @@
  */
 uint32_t dict_hash_multi(uint32_t hash, const char *key_part, size_t len);
 
+/*
+ * @brief Compute hash from a string.
+ */
+uint32_t dict_hash(const char *key, size_t len);
+
 /**
  * @brief Callback for checking hash table values equivalence.
  *