fixed stop appliaction error log
This commit is contained in:
parent
8116357d07
commit
281ab7b929
|
@ -22,7 +22,7 @@
|
||||||
|
|
||||||
-include("emqttd_protocol.hrl").
|
-include("emqttd_protocol.hrl").
|
||||||
|
|
||||||
-export([start/0, env/1, env/2, is_running/1]).
|
-export([start/0, env/1, env/2, is_running/1, stop/0]).
|
||||||
|
|
||||||
%% PubSub API
|
%% PubSub API
|
||||||
-export([subscribe/1, subscribe/2, subscribe/3, publish/1,
|
-export([subscribe/1, subscribe/2, subscribe/3, publish/1,
|
||||||
|
@ -57,6 +57,12 @@
|
||||||
-spec(start() -> ok | {error, any()}).
|
-spec(start() -> ok | {error, any()}).
|
||||||
start() -> application:start(?APP).
|
start() -> application:start(?APP).
|
||||||
|
|
||||||
|
%% @doc Stop emqttd application.
|
||||||
|
-spec(stop() -> ok | {error, any()}).
|
||||||
|
stop() ->
|
||||||
|
emqttd_plugins:unload(),
|
||||||
|
init:stop().
|
||||||
|
|
||||||
%% @doc Environment
|
%% @doc Environment
|
||||||
-spec(env(Key:: atom()) -> {ok, any()} | undefined).
|
-spec(env(Key:: atom()) -> {ok, any()} | undefined).
|
||||||
env(Key) -> application:get_env(?APP, Key).
|
env(Key) -> application:get_env(?APP, Key).
|
||||||
|
|
Loading…
Reference in New Issue