fixed bug in GraphGenerator