Commit 1f0ac78e authored by mo khan's avatar mo khan Committed by Lin Jen-Shin

Add comment to describe guard clause

parent 75602aba
...@@ -38,6 +38,8 @@ module Security ...@@ -38,6 +38,8 @@ module Security
def sync_vulnerability_rules def sync_vulnerability_rules
reports = pipeline.security_reports reports = pipeline.security_reports
# If we have some reports, then we want to sync them early;
# If we don't have reports, then we should wait until pipeline stops.
return if reports.empty? && !pipeline.complete? return if reports.empty? && !pipeline.complete?
return if reports.violates_default_policy? return if reports.violates_default_policy?
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment