format
This commit is contained in:
parent
0fd45bbf82
commit
ea7317e8eb
2 changed files with 6 additions and 1 deletions
|
@ -129,6 +129,7 @@ def bulk_post(data, :activities) do
|
||||||
{:error, %{reason: err}} ->
|
{:error, %{reason: err}} ->
|
||||||
Logger.error("Could not bulk put activity: #{err}")
|
Logger.error("Could not bulk put activity: #{err}")
|
||||||
:skipped
|
:skipped
|
||||||
|
|
||||||
{:ok, %{body: body}} ->
|
{:ok, %{body: body}} ->
|
||||||
IO.inspect(body)
|
IO.inspect(body)
|
||||||
:skipped
|
:skipped
|
||||||
|
@ -158,6 +159,7 @@ def bulk_post(data, :users) do
|
||||||
{:error, %{reason: err}} ->
|
{:error, %{reason: err}} ->
|
||||||
Logger.error("Could not bulk put users: #{err}")
|
Logger.error("Could not bulk put users: #{err}")
|
||||||
:skipped
|
:skipped
|
||||||
|
|
||||||
{:ok, %{body: body}} ->
|
{:ok, %{body: body}} ->
|
||||||
IO.inspect(body)
|
IO.inspect(body)
|
||||||
:skipped
|
:skipped
|
||||||
|
@ -187,6 +189,7 @@ def bulk_post(data, :hashtags) when is_list(data) do
|
||||||
{:error, %{reason: err}} ->
|
{:error, %{reason: err}} ->
|
||||||
Logger.error("Could not bulk put hashtags: #{err}")
|
Logger.error("Could not bulk put hashtags: #{err}")
|
||||||
:skipped
|
:skipped
|
||||||
|
|
||||||
{:ok, %{body: body}} ->
|
{:ok, %{body: body}} ->
|
||||||
IO.inspect(body)
|
IO.inspect(body)
|
||||||
:skipped
|
:skipped
|
||||||
|
|
|
@ -541,7 +541,9 @@ def handle_after_transaction(%Pleroma.Activity{data: %{"type" => "Create"}} = ac
|
||||||
Pleroma.Elasticsearch.put_by_id(:activity, activity.id)
|
Pleroma.Elasticsearch.put_by_id(:activity, activity.id)
|
||||||
end
|
end
|
||||||
|
|
||||||
def handle_after_transaction(%Pleroma.Activity{data: %{"type" => "Delete", "deleted_activity_id" => id}}) do
|
def handle_after_transaction(%Pleroma.Activity{
|
||||||
|
data: %{"type" => "Delete", "deleted_activity_id" => id}
|
||||||
|
}) do
|
||||||
Pleroma.Elasticsearch.delete_by_id(:activity, id)
|
Pleroma.Elasticsearch.delete_by_id(:activity, id)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue