]> git.donarmstrong.com Git - infobot.git/commitdiff
closed 17031 -- Fix up appending to factoids
authordms <dms@c11ca15a-4712-0410-83d8-924469b57eb5>
Fri, 11 Aug 2000 13:28:07 +0000 (13:28 +0000)
committerdms <dms@c11ca15a-4712-0410-83d8-924469b57eb5>
Fri, 11 Aug 2000 13:28:07 +0000 (13:28 +0000)
git-svn-id: https://svn.code.sf.net/p/infobot/code/trunk@36 c11ca15a-4712-0410-83d8-924469b57eb5

blootbot/src/Factoids/Update.pl

index de6cfa78848f1ca756ff65e8fb4ce1811e12f3b9..692d48dccbc3a7fa1169ac2218f69123c734f0ad 100644 (file)
@@ -78,9 +78,11 @@ sub update {
                        &status("orig factoid already had trailing symbol; not adding period.");
                        $rhs = $exists."  ".$rhs;
                    }
-               } elsif ($exists =~ /\,\s*$/) {
+               } elsif ($exists =~ /[\,\.\-]\s*$/) {
+                   &VERB("U: current has trailing symbols; inserting whitespace + new.",2);
                    $rhs = $exists." ".$rhs;
                } elsif ($rhs =~ /^\./) {
+                   &VERB("U: new text has ^.; appending directly",2);
                    $rhs = $exists.$rhs;
                } else {
                    $rhs = $exists.', or '.$rhs;