Module: ACTV::Authorable

Included in:
Article, Quiz
Defined in:
lib/actv/authorable.rb

Instance Method Summary collapse

Instance Method Details

#authorObject



4
5
6
# File 'lib/actv/authorable.rb', line 4

def author
  @author ||= author_from_reference || author_from_article
end

#author_name_from_by_lineObject



12
13
14
15
# File 'lib/actv/authorable.rb', line 12

def 
  author_name_regex = /by (.*)/i.match 
  author_name_regex[1].strip if author_name_regex.present?
end

#by_lineObject



8
9
10
# File 'lib/actv/authorable.rb', line 8

def 
  @by_line ||= description_by_type 'articleByLine'
end