Skip to content

Commit

Permalink
Only give Do operators what they need
Browse files Browse the repository at this point in the history
  • Loading branch information
camelpunch committed Dec 17, 2024
1 parent d68e004 commit a5ea33d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion lib/mudbrick.ex
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,7 @@ defmodule Mudbrick do
context
|> add(%ContentStream.QPush{})
|> add(ContentStream.Cm.new(cm_opts(image.value, opts)))
|> add(%ContentStream.Do{image: image.value})
|> add(%ContentStream.Do{image_identifier: image.value.resource_identifier})
|> add(%ContentStream.QPop{})

:error ->
Expand Down
4 changes: 2 additions & 2 deletions lib/mudbrick/content_stream/do.ex
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
defmodule Mudbrick.ContentStream.Do do
@moduledoc false
defstruct [:image]
defstruct [:image_identifier]

defimpl Mudbrick.Object do
def to_iodata(operator) do
[
Mudbrick.Object.to_iodata(operator.image.resource_identifier),
Mudbrick.Object.to_iodata(operator.image_identifier),
" Do"
]
end
Expand Down

0 comments on commit a5ea33d

Please sign in to comment.