FIx reassignment

This commit is contained in:
Ondřej 2024-08-09 14:34:25 +02:00
parent f9b0847b7f
commit 7df19883b1
2 changed files with 2 additions and 2 deletions

View file

@ -27,7 +27,7 @@ defmodule ChoreTracker.Chores do
def update_chore(%Chore{} = chore, attrs) do def update_chore(%Chore{} = chore, attrs) do
Ecto.Multi.new() Ecto.Multi.new()
|> Ecto.Multi.update(:chore, change_chore(chore, attrs)) |> Ecto.Multi.update(:chore, change_chore(chore, attrs))
|> Ecto.Multi.run(:update_next_assignee, fn _repo, _changeset -> |> Ecto.Multi.run(:update_next_assignee, fn _repo, %{chore: chore} ->
save_next_chore_assignee(chore) save_next_chore_assignee(chore)
end) end)
|> Repo.transaction() |> Repo.transaction()

View file

@ -1,5 +1,5 @@
<!DOCTYPE html> <!DOCTYPE html>
<html lang="en"> <html lang="en" class="[scrollbar-gutter:stable]">
<head> <head>
<meta charset="utf-8" /> <meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" /> <meta name="viewport" content="width=device-width, initial-scale=1" />