Fix unreference variable.
[cdist.git] / cdist
diff --git a/cdist b/cdist
index 1aff482f92954f4cc653e8c4fe7259c1f618b2ed..682924413cc5f5001a300873ac20e38cff882ab6 100755 (executable)
--- a/cdist
+++ b/cdist
@@ -906,6 +906,8 @@ class Tree(object):
             redirect = '>/dev/null'
         if config.has('git_reference'):
             ref = '--reference-if-able %s/%s.git' % (config.get('git_reference'), self.name)
+        else:
+            ref = ''
         command('git clone %s %s %s/%s.git %s/src/%s' % (flags, ref, config.get('git_prefix'), self.name, target.directory, self.name))
         os.chdir('%s/src/%s' % (target.directory, self.name))