Add Webhooks and XMPP notifications for incoming sats #79
@@ -11,7 +11,7 @@ class WebhooksController < ApplicationController
|
||||
head :unprocessable_entity and return
|
||||
end
|
||||
|
||||
user = User.find_by(ln_account: payload[:user_login])
|
||||
user = User.find_by!(ln_account: payload[:user_login])
|
||||
|
raucao marked this conversation as resolved
Outdated
|
||||
|
||||
# TODO make configurable
|
||||
notify_xmpp(user.address, payload[:amount], payload[:memo])
|
||||
|
||||
Reference in New Issue
Block a user
should not be the case, but this might be nil. maybe we should do a
User.find_by!Good idea! Fails much cleaner and more expressively than when trying to access properties on
nillater.