Permalink
Browse files

Add configurable notification api

  • Loading branch information...
1 parent 00d163c commit eae8746eb8cf4da81f7f6bc9310cb648d03ee661 @l4u l4u committed Aug 25, 2012
Showing with 6 additions and 1 deletion.
  1. +6 −1 src/airbrake.erl
View
@@ -25,7 +25,12 @@
handle_info/2]).
%% Constants
--define(NOTIFICATION_API, "http://airbrake.io/notifier_api/v2/notices").
+-define(NOTIFICATION_API, case application:get_env(notification_api) of
+ {ok, NotificationAPI} ->
+ NotificationAPI;
+ _ ->
+ "http://airbrake.io/notifier_api/v2/notices"
+end).
-define(SERVER, ?MODULE).
-record(state, {environment, api_key}).

0 comments on commit eae8746

Please sign in to comment.