ishapi 0.1.8.105 → 0.1.8.106

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 07cce58f4e91facf1ba3ab606ae00d620deef313edbe26e974e178663cb8841c
4
- data.tar.gz: 3dacb96bf78dc231711d712425f7e0258c03eb31b890dd488dd59c139a5f815f
3
+ metadata.gz: bfbab1b2afe18ad8e893cbd47aa9f295ca63a1cb74fc217a5a1156911e8f597b
4
+ data.tar.gz: 6829b1d990e8176d2797b6da47a5f879f44a2c93b5a0b6452e9ad45e9c0845b2
5
5
  SHA512:
6
- metadata.gz: 7c67f1d97af84fa183d8e40bd0221b2fd2b57c56b81684865f5a392f4b8f738c6ea7821bc7fa1c8651e3340d494ed64f69c664c54a06de7cdbbcb7344990dbd5
7
- data.tar.gz: 52bcd4cf7c3defb07b709c585d9e824d8e4463989eccaa57e48fd9ab05956b81b9500f3f541d0f6a732d2b308c4d78dbf0dfbf7c5d95d2375a56d7bdeacca3a5
6
+ metadata.gz: 4298e4091aa1e8a440f7e30b401e51b835c638af8d14526301124f9bbfa1e43fd00b3e54d5e4067aee967baf42c1dc76380e1f84f556180d3a0db3c219451bf5
7
+ data.tar.gz: 9085e06cd159878f1c6224bc4c426a58df3f38a96c1cb3a7ff3e810189c1ccdaff5014d1841899a8c7fd303a882172de24b73da8e44c19db10b0323efccd64a6
@@ -4,7 +4,7 @@ module Ishapi
4
4
  layout :false
5
5
 
6
6
  # before_action :check_profile, except: [ :test ]
7
- # before_action :set_current_ability
7
+ before_action :set_current_ability
8
8
 
9
9
  check_authorization
10
10
  skip_before_action :verify_authenticity_token
@@ -137,7 +137,8 @@ module Ishapi
137
137
  end
138
138
 
139
139
  def set_current_ability
140
- puts! current_user.email, '#set_current_ability() :: @current_user'
140
+ # puts! current_user.email, '#set_current_ability() :: @current_user'
141
+ @current_user ||= User.new
141
142
  @current_ability ||= ::Ishapi::Ability.new( @current_user )
142
143
  end
143
144
 
@@ -5,30 +5,27 @@
5
5
 
6
6
  key = [ @site, params.permit! ]
7
7
  json.cache! key do
8
- json.site do
9
- json.id @site.id.to_s
10
- json.domain @site.domain
11
- json.lang @site.lang
12
- json.langs @langs
13
- json.title @site.title
14
- json.subhead @site.subhead
15
- json.description @site.description
8
+ json.id @site.id.to_s
9
+ json.domain @site.domain
10
+ json.lang @site.lang
11
+ json.langs @langs
12
+ json.title @site.title
13
+ json.subhead @site.subhead
14
+ json.description @site.description
16
15
 
17
- json.is_ads_enabled @site.is_ads_enabled
18
- json.play_videos_in_preview @site.play_videos_in_preview
19
- json.newsitems_per_page @site.newsitems_per_page
16
+ json.is_ads_enabled @site.is_ads_enabled
17
+ json.play_videos_in_preview @site.play_videos_in_preview
18
+ json.newsitems_per_page @site.newsitems_per_page
20
19
 
21
- json.partial! 'ishapi/features/index', :features => @site.features, :resource => @site
22
- json.partial! 'ishapi/galleries/index', :galleries => @galleries, :resource => @site
23
- json.partial! 'ishapi/newsitems/index', :newsitems => @newsitems, :resource => @site
24
- json.partial! 'ishapi/reports/index', :reports => @reports, :resource => @site
25
- json.partial! 'ishapi/videos/index', :videos => @site.videos
26
-
27
- json.feature_tags do
28
- json.array! @feature_tags do |feature_tag|
29
- json.partial! 'ishapi/tags/widget', :tag => feature_tag
30
- end
20
+ json.partial! 'ishapi/features/index', :features => @site.features, :resource => @site
21
+ json.partial! 'ishapi/galleries/index', :galleries => @galleries, :resource => @site
22
+ json.partial! 'ishapi/newsitems/index', :newsitems => @newsitems, :resource => @site
23
+ json.partial! 'ishapi/reports/index', :reports => @reports, :resource => @site
24
+ json.partial! 'ishapi/videos/index', :videos => @site.videos
25
+
26
+ json.feature_tags do
27
+ json.array! @feature_tags do |feature_tag|
28
+ json.partial! 'ishapi/tags/widget', :tag => feature_tag
31
29
  end
32
-
33
30
  end
34
31
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ishapi
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.8.105
4
+ version: 0.1.8.106
5
5
  platform: ruby
6
6
  authors:
7
7
  - piousbox
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-01-07 00:00:00.000000000 Z
11
+ date: 2020-01-10 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails