diff --git a/lib/ansible/cli/pull.py b/lib/ansible/cli/pull.py index a4bb1218228..569d5299a67 100644 --- a/lib/ansible/cli/pull.py +++ b/lib/ansible/cli/pull.py @@ -188,9 +188,9 @@ class PullCLI(CLI): if self.options.purge: os.chdir('/') try: - shutil.rmtree(options.dest) + shutil.rmtree(self.options.dest) except Exception, e: - print >>sys.stderr, "Failed to remove %s: %s" % (options.dest, str(e)) + self.display.error("Failed to remove %s: %s" % (self.options.dest, str(e))) return rc