Skip to content

Commit

Permalink
Remove deprecated gen_server callback format_status/2
Browse files Browse the repository at this point in the history
The callback `format_status(Opt, StatusData)` is deprecated
from OTP 27 and give build warnings.
Remove them since they are optional and no-op's in our case.

Signed-off-by: Björn Svensson <[email protected]>
  • Loading branch information
bjosv committed Nov 4, 2024
1 parent d6bc8d1 commit 6272de1
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 12 deletions.
5 changes: 1 addition & 4 deletions src/ered.erl
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@

%% gen_server callbacks
-export([init/1, handle_call/3, handle_cast/2, handle_info/2,
terminate/2, code_change/3, format_status/2]).
terminate/2, code_change/3]).

-export_type([opt/0,
command/0,
Expand Down Expand Up @@ -334,9 +334,6 @@ terminate(_Reason, State) ->
code_change(_OldVsn, State, _Extra) ->
{ok, State}.

format_status(_Opt, Status) ->
Status.

%%%===================================================================
%%% Internal functions
%%%===================================================================
Expand Down
5 changes: 1 addition & 4 deletions src/ered_client.erl
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@

%% gen_server callbacks
-export([init/1, handle_call/3, handle_cast/2, handle_info/2,
terminate/2, code_change/3, format_status/2]).
terminate/2, code_change/3]).

-export_type([info_msg/0,
addr/0,
Expand Down Expand Up @@ -289,9 +289,6 @@ terminate(Reason, State) ->
code_change(_OldVsn, State, _Extra) ->
{ok, State}.

format_status(_Opt, Status) ->
Status.

%%%===================================================================
%%% Internal functions
%%%===================================================================
Expand Down
5 changes: 1 addition & 4 deletions src/ered_cluster.erl
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@

%% gen_server callbacks
-export([init/1, handle_call/3, handle_cast/2, handle_info/2,
terminate/2, code_change/3, format_status/2]).
terminate/2, code_change/3]).


-export_type([opt/0,
Expand Down Expand Up @@ -396,9 +396,6 @@ terminate(_Reason, State) ->
code_change(_OldVsn, State, _Extra) ->
{ok, State}.

format_status(_Opt, Status) ->
Status.

%%%===================================================================
%%% Internal functions
%%%===================================================================
Expand Down

0 comments on commit 6272de1

Please sign in to comment.