quick hack to fix directed_subgraph creating function