Switching routes

Wondering why I can switch a route one way but not the other.

Example.

I have DHCP IPs on both wired and wireless interfaces.

I can switch to the wireless route using the following command;
ip route change default via 192.168.0.1 dev wlan0

However, I cannot switch back using the following command.
ip route change default via 192.168.1.1 dev wan

Using ifconfig shows br-wan but the network file is 'wan' so I tried both and neither works.
What am I missing?

Try $(ifstatus wan|jsonfilter -e '@.l3_device') instead of wan.

Your wan has seemingly type bridge, so it is called as 'br-wan'.

Are you certain that you intended to place WAN into a bridge?

It's a two port device and this setup is supposed to do two different things. The file I'm showing, if I recall is to bridge the two ports in order to sniff packets. Data essentially just flows through the router. But, it also allows the router to be connected to either port to be used as a DHCP client.

This is the current file.

config interface 'loopback'
        option ifname 'lo'
        option proto 'static'
        option ipaddr '127.0.0.1'
        option netmask '255.0.0.0'

config interface 'wan'
        option ifname 'eth0.1 eth0.2'
        option force_link '1'
        option type 'bridge'
        option proto 'dhcp'
        option metric '20'

config interface 'wwan'
        option proto 'dhcp'
        option metric '10'

config switch
        option name 'switch0'
        option reset '1'
        option enable_vlan '1'

config switch_vlan
        option device 'switch0'
        option vlan '2'
        option ports '0 6t'

config switch_vlan
        option device 'switch0'
        option vlan '1'
        option ports '1 2 3 4 6t'

The problem is that more than one person has messed with the file so now I don't know what it should look like anymore.

Then simply reset the router to get a copy of the default config. Be sure to backup the current config first.

I've done that but then I lose the two functions above, pass-through and DHCP on both interfaces.