blob: 563b3729fcaf4dffe27e8fc3477a451f4b35bf86 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
defmodule Nola.IcecastAgent do
use Agent
def start_link() do
Agent.start_link(fn -> nil end, name: __MODULE__)
end
def update(stats) do
Agent.update(__MODULE__, fn _old -> stats end)
end
def get do
Agent.get(__MODULE__, fn stats -> stats end)
end
end
|