diff --git a/job_data.py b/job_data.py
index 23e8aacf56552c09e5c5f4e4cee8e1c22a65339b..d77389e262cd40294e8b52e93ff94bafc4c0c6a0 100644
--- a/job_data.py
+++ b/job_data.py
@@ -65,7 +65,7 @@ class job_data:
         image = None
         depends = []
         stage = "unknown"
-        artifacts = []
+        artifacts = None
         cache = []
         for line in file_string.splitlines():
             line = line.removesuffix("\n")
@@ -117,10 +117,10 @@ class job_data:
         name : str = self.location.replace(os.path.sep, '/')
         stage : str = self.stage
         needs = [ r.replace(os.path.sep, '/') for r in self.depends]
-        if len(self.artifact) != 0:
-            artifacts = self.artifact
+        if self.artifact is None:
+            artifact = "untracked"
         else:
-            artifacts = "untracked"
+            artifacts = self.artifact
         if len(self.cache) != 0:
             cache = self.cache
         else:
@@ -138,9 +138,10 @@ class job_data:
         if artifacts == "untracked":
             output = output + '\t' + 'artifacts:\n\t\tuntracked: true\n'
         else:
-            output = output + '\t' + 'artifacts:\n\t\tpaths:\n'
-            for artifact in artifacts:
-                output = output + "\t\t\t- \"" + artifact + '\"\n'
+            if len(artifacts) != 0: 
+                output = output + '\t' + 'artifacts:\n\t\tpaths:\n'
+                for artifact in artifacts:
+                    output = output + "\t\t\t- \"" + artifact + '\"\n'
         if cache is not None:
             if cache == "untracked":
                 output = output + '\t' + 'cache:\n\t\tuntracked: true\n'