Skip to content

Commit

Permalink
Fix mutable default values for function
Browse files Browse the repository at this point in the history
Default value: {} -> None, inside: if None -> {}

Change-Id: I97866f32dc1a8d74f52aa2810efdd96520516c7d
Closes-bug: #1519346
  • Loading branch information
penguinolog committed Nov 24, 2015
1 parent f31d8d5 commit a38bd79
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion devops/models/network.py
Original file line number Diff line number Diff line change
Expand Up @@ -258,11 +258,13 @@ def addresses(self):
@staticmethod
def interface_create(network, node, type='network',
mac_address=None, model='virtio',
interface_map={}):
interface_map=None):
"""Create interface
:rtype : Interface
"""
if interface_map is None:
interface_map = {}
interfaces = []

def _create(mac_addr=None):
Expand Down

0 comments on commit a38bd79

Please sign in to comment.