Skip to content

Commit

Permalink
Chore: less noise in custom projection logic
Browse files Browse the repository at this point in the history
  • Loading branch information
mindreframer committed Dec 27, 2024
1 parent 6e3ee2b commit d68a317
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/sample/projections/proj1.ex
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ defmodule Sample.Projections.Proj1 do
def handle_event(multi, data = %Data{}, {event, index}) do
multi =
Ecto.Multi.run(multi, {:event, index}, fn _repo, _changes ->
IO.inspect(event.data, label: "index-#{index}")
# IO.inspect(event.data, label: "index-#{index}")
Repo.insert_all("projection_proj1", [%{id: index, data: "OK"}])
{:ok, 1}
end)
Expand Down
2 changes: 1 addition & 1 deletion lib/sample/projections/proj2.ex
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ defmodule Sample.Projections.Proj2 do
def handle_event(multi, data = %Data{}, {event, index}) do
multi =
Ecto.Multi.run(multi, {:event, index}, fn _repo, _changes ->
IO.inspect(event.data, label: "index-#{index}")
# IO.inspect(event.data, label: "index-#{index}")
Repo.insert_all("projection_proj2", [%{id: index, data: "OK"}])
{:ok, 1}
end)
Expand Down

0 comments on commit d68a317

Please sign in to comment.