Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions documents/addon.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ client.subscription.createAddon('sub_I55auG9GnbsR8u',{
| Name | Type | Description |
|-------|-----------|--------------------------------------------------|
| subscriptionId* | boolean | The subscription ID to which the add-on is being added. |
| items* | object | Details of the add-on you want to create. |
| quantity* | integer | This specifies the number of units of the add-on to be charged to the customer. |
| items | array | All parameters listed [here](https://razorpay.com/docs/api/payments/subscriptions/#create-an-add-on) |
| quantity | integer | This specifies the number of units of the add-on to be charged to the customer. |

**Response:**
```json
Expand Down
4 changes: 3 additions & 1 deletion razorpay/resources/addon.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,9 @@ def delete(self, addon_id, data={}, **kwargs):
Args:
addon_id : Id for which addon object has to be deleted
"""
return super(Addon, self).delete(addon_id, data, **kwargs)
url = '{}/{}'.format(self.base_url, addon_id)

return self.delete_url(url, data, **kwargs)

def all(self, data={}, **kwargs):
""""
Expand Down
2 changes: 1 addition & 1 deletion tests/test_client_addon.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ def test_addon_fetch(self):
@responses.activate
def test_addon_delete(self):
result = []
url = '{}/{}/delete'.format(self.base_url, self.addon_id)
url = '{}/{}'.format(self.base_url, self.addon_id)
responses.add(responses.DELETE,
url,
status=200,
Expand Down