Skip to content

Commit

Permalink
Update main.py. Add commit comment
Browse files Browse the repository at this point in the history
  • Loading branch information
knewell committed Mar 10, 2020
1 parent 917b953 commit bb1a62a
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions main.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,8 @@ def addNewFlowRoute(self, flowRouteData=None):
cu.lock()

cu.load(template_path='template/set-flow-route.conf', template_vars=flowRouteData)
cu.commit()
comment = 'Flow Route added: {}'.format(flowRouteData['flowRouteName'])
cu.commit(comment=comment)
cu.unlock()
logger.info('Flow Route added ' + str(flowRouteData))

Expand Down Expand Up @@ -121,7 +122,8 @@ def modFlowRoute(self, flowRouteData=None):
cu = Config(dev)
cu.lock()
cu.load(template_path='template/set-flow-route.conf', template_vars=flowRouteData)
cu.commit()
comment = 'Flow Route modified: {}'.format(flowRouteData['flowRouteName'])
cu.commit(comment=comment)
cu.unlock()
logger.info('Flow Route modified ' + str(flowRouteData))

Expand Down Expand Up @@ -162,7 +164,8 @@ def delFlowRoute(self, flowRouteData=None):
cu = Config(dev)
cu.lock()
cu.load(template_path='template/delete-flow-route.conf', template_vars=flowRouteData, merge=True)
cu.commit()
comment = 'Flow Route deleted: {}'.format(flowRouteData['flowRouteName'])
cu.commit(comment=comment)
cu.unlock()
logger.info('Flow Route deleted ' + str(flowRouteData))

Expand Down

0 comments on commit bb1a62a

Please sign in to comment.