diff options
Diffstat (limited to 'sphinx/ext/graphviz.py')
-rw-r--r-- | sphinx/ext/graphviz.py | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/sphinx/ext/graphviz.py b/sphinx/ext/graphviz.py index 56831c64..71e7ba65 100644 --- a/sphinx/ext/graphviz.py +++ b/sphinx/ext/graphviz.py @@ -146,14 +146,8 @@ def render_dot(self, code, options, format, prefix='graphviz'): ).encode('utf-8') fname = '%s-%s.%s' % (prefix, sha1(hashkey).hexdigest(), format) - if hasattr(self.builder, 'imgpath'): - # HTML - relfn = posixpath.join(self.builder.imgpath, fname) - outfn = path.join(self.builder.outdir, '_images', fname) - else: - # LaTeX - relfn = fname - outfn = path.join(self.builder.outdir, fname) + relfn = posixpath.join(self.builder.imgpath, fname) + outfn = path.join(self.builder.outdir, self.builder.imagedir, fname) if path.isfile(outfn): return relfn, outfn |