From 794dbd24767c8ca856af22d280e3ce3a41e0d8d7 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Wed, 31 Dec 2008 14:54:22 -0500 Subject: fix moveprefs transition --- ikiwiki-transition | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) (limited to 'ikiwiki-transition') diff --git a/ikiwiki-transition b/ikiwiki-transition index b15d9f46b..599261a09 100755 --- a/ikiwiki-transition +++ b/ikiwiki-transition @@ -201,10 +201,15 @@ sub moveprefs { foreach my $admin (@{$config{adminuser}}) { my $a=IkiWiki::userinfo_get($admin, $field); if (defined $a && length $a && - $a ne $orig && # might already have been moved - defined $config{$field} && - length $config{$field}) { - $config{$field}=IkiWiki::pagespec_merge($config{$field}, $a); + # might already have been moved + (! defined $orig || $a ne $orig)) { + if (defined $config{$field} && + length $config{$field}) { + $config{$field}=IkiWiki::pagespec_merge($config{$field}, $a); + } + else { + $config{$field}=$a; + } } } } -- cgit v1.2.3