Skip to content

Commit

Permalink
Rename variables in Hare.Actor
Browse files Browse the repository at this point in the history
Callbacks allow to return either `:hibernate` **or** `timeout`.
Hence variables should be called `timeout`, rather than just
`hibernate`.
  • Loading branch information
take-five committed Jul 25, 2017
1 parent d4f8a97 commit 1c3f957
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions lib/hare/actor.ex
Original file line number Diff line number Diff line change
Expand Up @@ -142,14 +142,14 @@ defmodule Hare.Actor do
{:reply, reply, new_given} ->
{:reply, reply, State.set(state, new_given)}

{:reply, reply, new_given, hibernate} ->
{:reply, reply, State.set(state, new_given), hibernate}
{:reply, reply, new_given, timeout} ->
{:reply, reply, State.set(state, new_given), timeout}

{:noreply, new_given} ->
{:noreply, State.set(state, new_given)}

{:noreply, new_given, hibernate} ->
{:noreply, State.set(state, new_given), hibernate}
{:noreply, new_given, timeout} ->
{:noreply, State.set(state, new_given), timeout}

{:stop, reason, reply, new_given} ->
{:stop, reason, reply, State.set(state, new_given)}
Expand All @@ -165,8 +165,8 @@ defmodule Hare.Actor do
{:noreply, new_given} ->
{:noreply, State.set(state, new_given)}

{:noreply, new_given, hibernate} ->
{:noreply, State.set(state, new_given), hibernate}
{:noreply, new_given, timeout} ->
{:noreply, State.set(state, new_given), timeout}

{:stop, reason, new_given} ->
{:stop, reason, State.set(state, new_given)}
Expand All @@ -188,8 +188,8 @@ defmodule Hare.Actor do
{:noreply, new_given} ->
{:noreply, State.set(state, new_given)}

{:noreply, new_given, hibernate} ->
{:noreply, State.set(state, new_given), hibernate}
{:noreply, new_given, timeout} ->
{:noreply, State.set(state, new_given), timeout}

{:stop, reason, new_given} ->
{:stop, reason, State.set(state, new_given)}
Expand Down

0 comments on commit 1c3f957

Please sign in to comment.