From 8670a87255ae8ed7a439e3cff95dd5f3eed6be90 Mon Sep 17 00:00:00 2001 From: Hugo Date: Thu, 15 Mar 2018 21:52:41 +0200 Subject: [PATCH] Do not use a mutable data structure for argument default --- pylast/__init__.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/pylast/__init__.py b/pylast/__init__.py index f644f3c..13a8681 100644 --- a/pylast/__init__.py +++ b/pylast/__init__.py @@ -731,7 +731,10 @@ class _ShelfCacheBackend(object): class _Request(object): """Representing an abstract web service operation.""" - def __init__(self, network, method_name, params={}): + def __init__(self, network, method_name, params=None): + + if params is None: + params = {} self.network = network self.params = {}