Sha256: e2c70b67a1e54855206b02a6490f53c6a8f25e18dd6b401cf63fdade352360fe

Contents?: true

Size: 476 Bytes

Versions: 4

Compression:

Stored size: 476 Bytes

Contents

# frozen_string_literal: tru
module YoutubeVideo
  # comment's author infomation
  class Author
    attr_reader :author_name, :author_image_url, :author_channel_url,
                :like_count
    def initialize(data)
      return unless data
      @author_name = data['authorDisplayName']
      @author_image_url = data['authorProfileImageUrl']
      @author_channel_url = data['authorChannelUrl']
      @like_count = data['likeCount'].to_i
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
YPBT-0.2.9 lib/YPBT/author.rb
YPBT-0.2.8 lib/YPBT/author.rb
YPBT-0.2.6 lib/YPBT/author.rb
YPBT-0.2.5 lib/YPBT/author.rb