There's several places in the code where this type of thing exists: form_data.update({'vpnservice_id': vpnservice.id})
better would be this: form_data['vpnservice_id'] = vpnservice.id
This type of thing bothers me, so I'm going to clean it up.
Also fixed the two cases of:
if <some_string>.find(<some_other_string>) != -1:
which should clearly use the "in" operator instead.
Reviewed: https:/ /review. openstack. org/105851 /git.openstack. org/cgit/ openstack/ horizon/ commit/ ?id=28e5874eb71 3b3589cbe393bc9 cefbf6041a6818
Committed: https:/
Submitter: Jenkins
Branch: master
commit 28e5874eb713b35 89cbe393bc9cefb f6041a6818
Author: woodm1979 <email address hidden>
Date: Wed Jul 9 13:31:45 2014 -0600
Cleaned up dict.update(single elem dict) code
There's several places in the code where this type of thing exists:
form_data. update( {'vpnservice_ id': vpnservice.id})
form_data[ 'vpnservice_ id'] = vpnservice.id
better would be this:
This type of thing bothers me, so I'm going to clean it up.
Also fixed the two cases of: .find(< some_other_ string> ) != -1:
if <some_string>
which should clearly use the "in" operator instead.
Change-Id: Ic72a5b0a17c211 f3949edc69732c1 101c24590ec
Closes-Bug: 1339849