Looks like the base problem is that empty is being interpreted as "put empty in the sig" instead of as "use default sig" at signature replacement time.
We shouldn't be saving the username into preferences if it hasn't been explicitly typed; if the user changes their name, they should automatically pick up the new value.
// When no fancy sig used, make sure ~{3,5} get removed.
$signature = $wgParser->cleanSigInSig( $signature );
}
-
- global $wgUser;
- if (!$signature) $signature = $wgUser->getName();
return $signature;
}