X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=lib%2Fstemmaweb%2FController%2FRoot.pm;h=51d7dff1255922c62704d22d70381120124a2bba;hb=4770d07784e75a7f842b061a359f7e4d5644fe51;hp=f2488ad09e07571c78acca97e7f32475a5e963c0;hpb=1acbd103648a939e82ff5bc0c58d30492e59fdcb;p=scpubgit%2Fstemmaweb.git diff --git a/lib/stemmaweb/Controller/Root.pm b/lib/stemmaweb/Controller/Root.pm index f2488ad..51d7dff 100644 --- a/lib/stemmaweb/Controller/Root.pm +++ b/lib/stemmaweb/Controller/Root.pm @@ -352,10 +352,10 @@ sub stemma :Local :Args(2) { if( $ok eq 'full' ) { my $dot = $c->request->body_params->{'dot'}; # Graph::Reader::Dot does not handle bare unicode. We get around this - # by wrapping all words in double quotes, but then we have to undo it - # for the initial 'digraph stemma' statement. Horrible hack. - $dot =~ s/\b(\w+)\b/"$1"/g; - $dot =~ s/"(digraph|stemma)"/$1/g; + # by wrapping all words in double quotes, as long as they aren't already + # wrapped, and as long as they aren't the initial 'digraph stemma'. + # Horrible HACK. + $dot =~ s/(?