wan: switching IPv4 protocol settings should not leave incompatible options in uci config
For example:
"dhcp" for IPv4 creates following config:
config interface 'wan'
option device 'eth2'
option proto 'dhcp'
Upon switching to "Static IP address" it is still fine:
config interface 'wan'
option device 'eth2'
option proto 'static'
option ipaddr '10.0.1.185'
option netmask '255.255.255.0'
option gateway '10.0.1.1'
However changing it back to "dhcp" leaves the "static ip" options intact.
config interface 'wan''
option device 'eth2'
option ipaddr '10.0.1.185' <-- this should not stay here
option netmask '255.255.255.0' <-- this should not stay here
option gateway '10.0.1.1' <-- this should not stay here
option proto 'dhcp'
Related to: #226