Merge branch 'develop' into issue/1276

This commit is contained in:
Maksim Pechnikov 2019-11-04 20:24:53 +03:00
commit ff6c727739
35 changed files with 605 additions and 234 deletions

View file

@ -8,10 +8,10 @@ defmodule Pleroma.Repo.Migrations.MigrateOldBookmarks do
def up do
query =
from(u in User,
from(u in "users",
where: u.local == true,
where: fragment("array_length(bookmarks, 1)") > 0,
select: %{id: u.id, bookmarks: fragment("bookmarks")}
where: fragment("array_length(?, 1)", u.bookmarks) > 0,
select: %{id: u.id, bookmarks: u.bookmarks}
)
Repo.stream(query)