Skip to content
Snippets Groups Projects

Add handling for bad data in ci_build options

Closed Jeremy Jackson requested to merge fix-ci-build-options-serialization into master
3 unresolved threads
2 files
+ 3
9
Compare changes
  • Side-by-side
  • Inline
Files
2
+ 0
8
@@ -767,14 +767,6 @@ def valid_dependency?
@@ -767,14 +767,6 @@ def valid_dependency?
true
true
end
end
def options
@options ||= begin
return self[:options] if self[:options].is_a?(HashWithIndifferentAccess)
# for really bad data handling scenarios, barely production ready
HashWithIndifferentAccess.new(JSON.parse(self[:options].gsub('=>', ':'))) rescue { }
end
end
def invalid_dependencies
def invalid_dependencies
dependencies.reject(&:valid_dependency?)
dependencies.reject(&:valid_dependency?)
end
end
Loading