FIX: don't stop youtube when liking a post

Also fixes post action create/destroy api not to include post raw.
This commit is contained in:
Sam
2014-09-25 12:02:41 +10:00
parent c43f6455f2
commit e14e8f64bc
3 changed files with 18 additions and 6 deletions

View File

@ -355,9 +355,9 @@ class ApplicationController < ActionController::Base
protected
def render_post_json(post)
def render_post_json(post, add_raw=true)
post_serializer = PostSerializer.new(post, scope: guardian, root: false)
post_serializer.add_raw = true
post_serializer.add_raw = add_raw
post_serializer.topic_slug = post.topic.slug if post.topic.present?
counts = PostAction.counts_for([post], current_user)