nov/fb_graph — pull request #366 by avokhmin (2014-08-05 12:55:31+00:00)
Title: Fetch images from a post + refactoring

Fetches images from a post.

Example form [FB graph](https://graph.facebook.com/10152440606793600/):

```
"images": [
{
"height": 688,
"source": "https://scontent-a.xx.fbcdn.net/hphotos-xpa1/v/t1.0-9/10561773_10152440606793600_1776025110345181258_n.jpg?oh=4906f82b8953e685cf8162317ab38d87&oe=54405E40",
"width": 957
}, ...
]

```

How to reproduce:

```
[8] pry(main)> post = FbGraph::Post.new('10152440606793600', access_token: access_token).fetch
=> #
[9] pry(main)> post.images
NoMethodError: undefined method `images' for #
[10] pry(main)> post.raw_attributes['images']
=> [{"height"=>688,
"source"=>
"https://scontent-a.xx.fbcdn.net/hphotos-xpa1/v/t1.0-9/10561773_10152440606793600_1776025110345181258_n.jpg?oh=4906f82b8953e685cf8162317ab38d87&oe=54405E40",
"width"=>957}, ...]
```

So, I did small refactoring according to [new style](https://github.com/nov/fb_graph/blob/master/lib/fb_graph/ad_campaign_group.rb#L18-L20) and added fetching of images