Explorar el Código

Fixed hide() to store the object id, not its md5.

default hace 3 años
padre
commit
2176a91c64
Se han modificado 1 ficheros con 9 adiciones y 2 borrados
  1. 9 2
      data.c

+ 9 - 2
data.c

@@ -1097,8 +1097,15 @@ void hide(snac *snac, const char *id)
         char *p, *v;
         char *p, *v;
 
 
         p = chld;
         p = chld;
-        while (xs_list_iter(&p, &v))
-            hide(snac, v);
+        while (xs_list_iter(&p, &v)) {
+            xs *co = NULL;
+
+            /* resolve to get the id */
+            if (valid_status(object_get_by_md5(v, &co, NULL))) {
+                if ((v = xs_dict_get(co, "id")) != NULL)
+                    hide(snac, v);
+            }
+        }
     }
     }
 }
 }