From 1fb49c587e439503dd747c71bae11d723b98766d Mon Sep 17 00:00:00 2001 From: Joseph Hunkeler Date: Mon, 19 Mar 2018 14:08:29 -0400 Subject: Fix spec file verification logic --- pipeline_backup.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'pipeline_backup.py') diff --git a/pipeline_backup.py b/pipeline_backup.py index b32260f..e1f5e2e 100755 --- a/pipeline_backup.py +++ b/pipeline_backup.py @@ -32,10 +32,10 @@ class PipelineSpec: def verify(self): with open(self.filename, 'r') as fp: - if '@EXPLICIT' not in fp.readlines(): - return False - - return True + for line in fp: + if line.startswith('@EXPLICIT'): + return True + return False def _read(self): if not self.verify(): -- cgit