From 5636e057948edc46b9cd5b1eb87f9cf420204adc Mon Sep 17 00:00:00 2001 From: Christian Poessinger Date: Sat, 21 Mar 2020 11:19:42 +0100 Subject: sstp: T2008: bugfix migrator for radius options An if statement was missing to check if there are really additional radius-settings or not. --- src/migration-scripts/sstp/0-to-1 | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/migration-scripts/sstp/0-to-1') diff --git a/src/migration-scripts/sstp/0-to-1 b/src/migration-scripts/sstp/0-to-1 index 1d1bea51f..0e8dd1c4b 100755 --- a/src/migration-scripts/sstp/0-to-1 +++ b/src/migration-scripts/sstp/0-to-1 @@ -69,10 +69,10 @@ else: # migrate radius options - copy subtree # thus must happen before migration of the individual RADIUS servers old_options = new_base + ['authentication', 'radius-settings'] - new_options = new_base + ['authentication', 'radius'] - config.copy(old_options, new_options) - config.delete(old_options) - + if config.exists(old_options): + new_options = new_base + ['authentication', 'radius'] + config.copy(old_options, new_options) + config.delete(old_options) # migrate radius dynamic author / change of authorisation server dae_old = new_base + ['authentication', 'radius', 'dae-server'] -- cgit v1.2.3