Skip to content

Commit

Permalink
On update, try to redeploy if EVC is enabled. (kytos#60)
Browse files Browse the repository at this point in the history
When EVC is inactive, only if the enable field was updated
the deploy method was called. Now, always call it
if EVC is enabled.
Fixes kytos#38

Co-authored-by: Italo Valcy S Brito <[email protected]>
  • Loading branch information
Antonio Francisco and italovalcy committed Oct 4, 2021
1 parent 8dec828 commit bc6a345
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion main.py
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,7 @@ def update(self, circuit_id):
evc.remove()
evc.deploy()
else:
if enable is True: # enable if inactive
if evc.is_enabled(): # enable if inactive
with evc.lock:
evc.deploy()
result = {evc.id: evc.as_dict()}
Expand Down

0 comments on commit bc6a345

Please sign in to comment.