Sha256: d6666e4fc180cba3f320ef85d02c2800534149d1b27553ecffcc50643dfd42d5

Contents?: true

Size: 464 Bytes

Versions: 12

Compression:

Stored size: 464 Bytes

Contents

require 'yt/video_audit/base'

module Yt
  module VideoAudit
    # Count how many subject videos have an info card.
    class InfoCard < Base
      def title
        'Info Cards'
      end

      def description
        'The number of videos with an info card'
      end

    private

      def valid?(video)
        Yt::Annotations.for(video.id).any? do |annotation|
          annotation.instance_of? Yt::Annotations::Card
        end
      end
    end
  end
end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
yt-audit-0.6.0 lib/yt/video_audit/info_card.rb
yt-audit-0.5.5 lib/yt/video_audit/info_card.rb
yt-audit-0.5.4 lib/yt/video_audit/info_card.rb
yt-audit-0.5.3 lib/yt/video_audit/info_card.rb
yt-audit-0.5.2 lib/yt/video_audit/info_card.rb
yt-audit-0.5.1 lib/yt/video_audit/info_card.rb
yt-audit-0.5.0 lib/yt/video_audit/info_card.rb
yt-audit-0.4.0 lib/yt/video_audit/info_card.rb
yt-audit-0.3.2 lib/yt/video_audit/info_card.rb
yt-audit-0.3.1 lib/yt/video_audit/info_card.rb
yt-audit-0.3.0 lib/yt/video_audit/info_card.rb
yt-audit-0.2.2 lib/yt/video_audit/info_card.rb