Commit b9bf9884e803257d5fcc0dc05e43a626ed25831a

Authored by Karpikau Andrei
1 parent 2abd42b9

check crash

@@ -3,7 +3,7 @@ module Kanjai @@ -3,7 +3,7 @@ module Kanjai
3 3
4 include Admin::PagesHelper 4 include Admin::PagesHelper
5 5
6 - after_action :skip_set_cookies_header 6 + #after_action :skip_set_cookies_header
7 7
8 8
9 def show 9 def show
@@ -38,17 +38,14 @@ module Kanjai @@ -38,17 +38,14 @@ module Kanjai
38 38
39 #render :text => content_for_render and return 39 #render :text => content_for_render and return
40 else 40 else
41 - #if stale?(@page_data, public: false)  
42 - #TODO NEED CHECK CACHE  
43 - #if stale?(last_modified: @page_data.last_modified, etag: @page_data.cache_key_with_version) 41 + if stale?(last_modified: @page_data.last_modified, etag: @page_data.cache_key_with_version)
44 layer = @page_data.page.page_template.get_html_content 42 layer = @page_data.page.page_template.get_html_content
45 content_for_render = setTemplateContent(@page_data.page.page_template, layer, @page_data) 43 content_for_render = setTemplateContent(@page_data.page.page_template, layer, @page_data)
46 respond_to do |format| 44 respond_to do |format|
47 format.html{render :plain => content_for_render} 45 format.html{render :plain => content_for_render}
48 end 46 end
49 - #end 47 + end
50 end 48 end
51 - #render :html => content_for_render.html_safe  
52 else 49 else
53 page_content = get_html_by_json_client(@page_data) 50 page_content = get_html_by_json_client(@page_data)
54 render :html => page_content.html_safe and return 51 render :html => page_content.html_safe and return
1 module Kanjai 1 module Kanjai
2 - VERSION = "0.0.138" 2 + VERSION = "0.0.139"
3 end 3 end