For note, you can initialize your state map in your init callback by setting it to, oh, %{pid: nil} or something.
init
%{pid: nil}