Added graph handling