@@ 15,13 15,11 @@ end
require_relative "lib/electrum"
-if ENV["RACK_ENV"] == "production"
- require "sentry-ruby"
- Sentry.init do |config|
- config.traces_sample_rate = 1
- end
- use Sentry::Rack::CaptureExceptions
+require "sentry-ruby"
+Sentry.init do |config|
+ config.traces_sample_rate = 1
end
+use Sentry::Rack::CaptureExceptions
REDIS = Redis.new
PLANS = Dhall.load("env:PLANS").sync
@@ 214,6 212,14 @@ class JmpPay < Roda
)
r.on "activate" do
+ Sentry.configure_scope do |scope|
+ scope.set_transaction_name("activate")
+ scope.set_context(
+ "activate",
+ plan_name: request.params["plan_name"]
+ )
+ end
+
render = lambda do |l={}|
view(
"activate",