mirror of
https://github.com/philomena-dev/philomena.git
synced 2025-01-20 06:37:59 +01:00
stop casting for now and just spawn off
This commit is contained in:
parent
d24c97dad8
commit
5e99152837
1 changed files with 5 additions and 2 deletions
|
@ -5,7 +5,7 @@ defmodule PhilomenaWeb.ImageController do
|
||||||
alias PhilomenaWeb.CommentLoader
|
alias PhilomenaWeb.CommentLoader
|
||||||
alias PhilomenaWeb.NotificationCountPlug
|
alias PhilomenaWeb.NotificationCountPlug
|
||||||
alias Philomena.{Images, Images.Image, Comments.Comment, Galleries.Gallery, Galleries.Interaction, Textile.Renderer}
|
alias Philomena.{Images, Images.Image, Comments.Comment, Galleries.Gallery, Galleries.Interaction, Textile.Renderer}
|
||||||
alias Philomena.Servers.ImageProcessor
|
# alias Philomena.Servers.ImageProcessor
|
||||||
alias Philomena.UserStatistics
|
alias Philomena.UserStatistics
|
||||||
alias Philomena.Interactions
|
alias Philomena.Interactions
|
||||||
alias Philomena.Comments
|
alias Philomena.Comments
|
||||||
|
@ -100,7 +100,10 @@ defmodule PhilomenaWeb.ImageController do
|
||||||
|
|
||||||
case Images.create_image(attributes, image_params) do
|
case Images.create_image(attributes, image_params) do
|
||||||
{:ok, %{image: image}} ->
|
{:ok, %{image: image}} ->
|
||||||
ImageProcessor.cast(image.id)
|
spawn fn ->
|
||||||
|
Images.repair_image(image)
|
||||||
|
end
|
||||||
|
# ImageProcessor.cast(image.id)
|
||||||
Images.reindex_image(image)
|
Images.reindex_image(image)
|
||||||
Tags.reindex_tags(image.added_tags)
|
Tags.reindex_tags(image.added_tags)
|
||||||
UserStatistics.inc_stat(conn.assigns.current_user, :uploads)
|
UserStatistics.inc_stat(conn.assigns.current_user, :uploads)
|
||||||
|
|
Loading…
Reference in a new issue