]> review.fuel-infra Code Review - openstack-build/neutron-build.git/commit
Refactor awkward logic in setup_dhcp_port
authorCarl Baldwin <carl.baldwin@hp.com>
Thu, 4 Jun 2015 22:25:44 +0000 (22:25 +0000)
committerCarl Baldwin <carl.baldwin@hp.com>
Fri, 5 Jun 2015 20:18:36 +0000 (20:18 +0000)
commit713ba0e8d7ce59eaff41518360530b2e7831c322
tree5ae5b304ce69c957edc03710467c07c1a19c3caa
parent2acdbf3bac7f4a967e2ef8f98b2ac14fa0f7f861
Refactor awkward logic in setup_dhcp_port

I noticed this logic as I was reviewing another patch set [1].  I
didn't like removing subnet ids from dhcp_enabled_subnet_ids and I
wasn't too keen on the ips_need_removal semantics that were kind of
forced by the existing structure of the code.  I hope you find this
alternative much clearer.  I like straight-forward code with less
indentation that doesn't use awkward booleans like ips_needs_removal.

[1] https://review.openstack.org/#/c/157697/6

Change-Id: I8bd3d6924a855ea08f8096e66bd3bfbb165a4da3
neutron/agent/linux/dhcp.py