class FedenaSdk::News

Attributes

author[RW]
content[RW]
title[RW]

Public Class Methods

all(_count = nil) click to toggle source
# File lib/fedena_sdk/news.rb, line 4
def self.all(_count = nil)
  url = '/api/news'
  hash = get(url)
  hash['news_detail']['news'].map do |news_hash|
    new news_hash
  end
end

Public Instance Methods

author_user() click to toggle source
# File lib/fedena_sdk/news.rb, line 12
def author_user
  User.find(@author)
end