Skip to content

Commit 8cb5008

Browse files
committed
Fix DataBuffer child_spec
1 parent e6fc7dc commit 8cb5008

1 file changed

Lines changed: 4 additions & 5 deletions

File tree

lib/data_buffer.ex

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ defmodule DataBuffer do
101101
Supervisor.init(children, strategy: :one_for_one)
102102
end
103103

104-
defmacro __using__(opts) do
104+
defmacro __using__(_opts) do
105105
quote location: :keep do
106106
@behaviour DataBuffer
107107

@@ -114,12 +114,11 @@ defmodule DataBuffer do
114114
end
115115

116116
def child_spec(opts) do
117-
default = %{
117+
%{
118118
id: __MODULE__,
119-
start: {__MODULE__, :start_link, [opts]}
119+
start: {__MODULE__, :start_link, [opts]},
120+
type: :supervisor
120121
}
121-
122-
Supervisor.child_spec(default, unquote(Macro.escape(opts)))
123122
end
124123

125124
defoverridable(child_spec: 1)

0 commit comments

Comments
 (0)