small fix
This commit is contained in:
parent
9938585a5a
commit
28937534fe
|
@ -294,7 +294,8 @@ class AnnouncementsController < ApplicationController
|
||||||
desc = (desc.nil? || desc == "" ? "announcement image" : desc)
|
desc = (desc.nil? || desc == "" ? "announcement image" : desc)
|
||||||
|
|
||||||
request = OrbitHelper.request
|
request = OrbitHelper.request
|
||||||
meta_desc = announcement["subtitle_translations"][locale] == "" ? announcement["text_translations"][locale][0..200] : announcement["subtitle_translations"][locale]
|
meta_desc = announcement["subtitle_translations"].present? && announcement["subtitle_translations"][locale] != "" ? announcement["subtitle_translations"][locale] : announcement["text_translations"][locale][0..200]
|
||||||
|
|
||||||
OrbitHelper.render_meta_tags([{"property" => "og:title", "content" => announcement["title_translations"][locale]},{"property" => "og:site_name", "content" => Site.first.title},{"property" => "og:url", "content" => request.original_url},{"property" => "og:description", "content" => meta_desc},{"property" => "og:image", "content" => announcement["image"]["original"]},{"property" => "og:type", "content" => "Article"}])
|
OrbitHelper.render_meta_tags([{"property" => "og:title", "content" => announcement["title_translations"][locale]},{"property" => "og:site_name", "content" => Site.first.title},{"property" => "og:url", "content" => request.original_url},{"property" => "og:description", "content" => meta_desc},{"property" => "og:image", "content" => announcement["image"]["original"]},{"property" => "og:type", "content" => "Article"}])
|
||||||
|
|
||||||
datetime = DateTime.parse(announcement["postdate"])
|
datetime = DateTime.parse(announcement["postdate"])
|
||||||
|
|
Loading…
Reference in New Issue