From 7481721d6db1f64115f3341afaef6183c8970d42 Mon Sep 17 00:00:00 2001 From: Luna D Date: Mon, 29 May 2023 14:20:57 +0200 Subject: [PATCH] fix dupe merger --- lib/philomena/images.ex | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/philomena/images.ex b/lib/philomena/images.ex index 600f1a71..4239f877 100644 --- a/lib/philomena/images.ex +++ b/lib/philomena/images.ex @@ -17,6 +17,7 @@ defmodule Philomena.Images do alias Philomena.Images.Uploader alias Philomena.Images.Tagging alias Philomena.Images.Thumbnailer + alias Philomena.Images.Source alias Philomena.Images.ElasticsearchIndex, as: ImageIndex alias Philomena.IndexWorker alias Philomena.ImageFeatures.ImageFeature @@ -930,6 +931,7 @@ defmodule Philomena.Images do def migrate_sources(source, target) do sources = (source.sources ++ target.sources) + |> Enum.map(fn s -> %Source{image_id: target.id, source: s.source} end) |> Enum.uniq() |> Enum.take(10)