From 63f45a57eeeb17779b95c8acd2ffc513a2218b81 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ioan=20Biz=C4=83u?= Date: Thu, 22 Feb 2024 11:29:00 +0200 Subject: [PATCH] Forbid bidding on one's own auction. --- api/api.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/api/api.py b/api/api.py index fb0b9385..3d17919e 100644 --- a/api/api.py +++ b/api/api.py @@ -1143,7 +1143,7 @@ def post_auction_bid(merchant_pubkey, auction_event_id): birdwatcher = get_birdwatcher() - if request.json['pubkey'] == merchant_pubkey: + if request.json['pubkey'] == merchant_pubkey or request.json['pubkey'] == merchant.nostr_public_key: message = "Cannot bid on one's own auction!" birdwatcher.publish_bid_status(auction, request.json['id'], 'rejected', message) return jsonify({'message': message}), 400