lib/git/lint/analyzer.rb in git-lint-4.6.0 vs lib/git/lint/analyzer.rb in git-lint-5.0.0

- old
+ new

@@ -18,18 +18,29 @@ Analyzers::CommitBodyParagraphCapitalization, Analyzers::CommitBodyPhrase, Analyzers::CommitBodyPresence, Analyzers::CommitBodySingleBullet, Analyzers::CommitBodyTrackerShorthand, + Analyzers::CommitSignature, Analyzers::CommitSubjectLength, Analyzers::CommitSubjectPrefix, Analyzers::CommitSubjectSuffix, Analyzers::CommitTrailerCollaboratorCapitalization, - Analyzers::CommitTrailerCollaboratorDuplication, Analyzers::CommitTrailerCollaboratorEmail, Analyzers::CommitTrailerCollaboratorKey, - Analyzers::CommitTrailerCollaboratorName + Analyzers::CommitTrailerCollaboratorName, + Analyzers::CommitTrailerDuplicate, + Analyzers::CommitTrailerFormatKey, + Analyzers::CommitTrailerFormatValue, + Analyzers::CommitTrailerIssueKey, + Analyzers::CommitTrailerIssueValue, + Analyzers::CommitTrailerSignerCapitalization, + Analyzers::CommitTrailerSignerEmail, + Analyzers::CommitTrailerSignerKey, + Analyzers::CommitTrailerSignerName, + Analyzers::CommitTrailerTrackerKey, + Analyzers::CommitTrailerTrackerValue ].freeze # rubocop:disable Metrics/ParameterLists def initialize analyzers: ANALYZERS, collector: Collector.new, @@ -52,10 +63,10 @@ attr_reader :analyzers, :collector, :reporter def process commits collector.clear - commits.map { |commit| analyze commit } + commits.value_or([]).map { |commit| analyze commit } end def analyze commit settings.map { |setting| load_analyzer commit, setting.id } .select(&:enabled?)