Skip to content

Avoid using mutable defaults. #134

Description

@imkaka

Mutable {} is used in functions everywhere in the project, which can lead to leaks if these functions are not called properly.
refer - https://florimond.dev/blog/articles/2018/08/python-mutable-defaults-are-the-source-of-all-evil/

def capture(self, payment_id, amount, data={}, **kwargs):

def refund(self, payment_id, amount, data={}, **kwargs):  # pragma: no cover

Metadata

Metadata

Assignees

Labels

Type

No type

Fields

No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions