mirror of
https://github.com/discourse/discourse.git
synced 2024-11-23 23:06:57 +08:00
FIX: API should return post_action or nil, true is wrong
This commit is contained in:
parent
e0a82d3088
commit
9ba8b29e98
|
@ -238,7 +238,7 @@ class PostAction < ActiveRecord::Base
|
||||||
rescue ActiveRecord::RecordNotUnique
|
rescue ActiveRecord::RecordNotUnique
|
||||||
# can happen despite being .create
|
# can happen despite being .create
|
||||||
# since already bookmarked
|
# since already bookmarked
|
||||||
true
|
PostAction.where(where_attrs).first
|
||||||
end
|
end
|
||||||
|
|
||||||
def self.remove_act(user, post, post_action_type_id)
|
def self.remove_act(user, post, post_action_type_id)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user