fuel 0.4.4 → 0.4.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b8e8a89c308a846a23bb2c1ef406b6f927e79660
|
4
|
+
data.tar.gz: 84d0908974fb71d54c6eb58ad56813e680d4b096
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 46e7ffb95aea51f734544c09dc652330a07876cd9091056587da8cc9e1b424dd346bf126bd992516985e0fa00273167bf2b2a4e4e4ca0522b397b2d4a0ea9a74
|
7
|
+
data.tar.gz: b6e0aa800d0de281182914fc7274031cbfd2ec4a9306f8a44ff35c88a8262880b1635a70ae02e83c1c704cda95ac57d92dd6eedf994e87cda4a5290fc0587c83
|
@@ -12,6 +12,11 @@ module Fuel
|
|
12
12
|
@posts = Fuel::Post.recent_published_posts.page(params[:page])
|
13
13
|
@title = Fuel.configuration.blog_title
|
14
14
|
@description = Fuel.configuration.blog_description
|
15
|
+
|
16
|
+
respond_to do |format|
|
17
|
+
format.html
|
18
|
+
format.json { render json: @posts, :methods => [:avatar_url, :featured_image_url] }
|
19
|
+
end
|
15
20
|
end
|
16
21
|
|
17
22
|
def show
|
@@ -19,6 +24,11 @@ module Fuel
|
|
19
24
|
@title = truncate_on_space(@post.seo_title || @post.title, 70)
|
20
25
|
@description = @post.seo_description
|
21
26
|
@disqus_name = Fuel.configuration.disqus_name
|
27
|
+
|
28
|
+
respond_to do |format|
|
29
|
+
format.html
|
30
|
+
format.json { render json: @post, :methods => [:avatar_url, :featured_image_url] }
|
31
|
+
end
|
22
32
|
end
|
23
33
|
|
24
34
|
def preview
|
data/app/models/fuel/post.rb
CHANGED
@@ -33,7 +33,7 @@ module Fuel
|
|
33
33
|
end
|
34
34
|
|
35
35
|
def s3_credentials
|
36
|
-
{:bucket => Fuel.configuration.aws_bucket, :access_key_id => Fuel.configuration.aws_access_key, :secret_access_key => Fuel.configuration.aws_secret_access_key}
|
36
|
+
{ :bucket => Fuel.configuration.aws_bucket, :access_key_id => Fuel.configuration.aws_access_key, :secret_access_key => Fuel.configuration.aws_secret_access_key, :s3_protocol => 'https' }
|
37
37
|
end
|
38
38
|
|
39
39
|
def next
|
@@ -86,5 +86,13 @@ module Fuel
|
|
86
86
|
format == Formats::MARKDOWN
|
87
87
|
end
|
88
88
|
|
89
|
+
def featured_image_url
|
90
|
+
featured_image.url(:medium)
|
91
|
+
end
|
92
|
+
|
93
|
+
def avatar_url
|
94
|
+
return unless author.present?
|
95
|
+
author.avatar.url(:medium)
|
96
|
+
end
|
89
97
|
end
|
90
98
|
end
|
data/lib/fuel/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: fuel
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.4.
|
4
|
+
version: 0.4.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ryan Francis
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2016-03-01 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|