Skip to content

Commit

Permalink
Use ensure_started over start
Browse files Browse the repository at this point in the history
This makes sure if the application is already started, it doesn't try to
start it again
  • Loading branch information
aellispierce committed Feb 2, 2017
1 parent d128583 commit 36243c9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/mix/tasks/redbird/delete_all_sessions.ex
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ defmodule Mix.Tasks.Redbird.DeleteAllSessions do
session config. If no argument is given, it will delete all redbird sessions.
"""
def run(_args) do
Redbird.start(nil, nil)
Application.ensure_started(:redbird)
Plug.Session.REDIS.namespace
|> delete_all_sessions
end
Expand Down

0 comments on commit 36243c9

Please sign in to comment.