add suport for old erlang