#!/bin/sh

. /lib/functions.sh

rename_option() {
	SECTION="$1"
	config_get "proto" "$SECTION" "proto"
	if [ "$proto" = "sstp" ]; then
		uci_rename "network" "$SECTION" "_device_files" "device_files"
	fi
}

config_load "network"
config_foreach "rename_option" "interface"
uci_commit "network"
