Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Merge branch 'master' into Item13525
  • Loading branch information
MichaelDaum committed Jul 23, 2015
2 parents 38024e2 + 873b485 commit 34c1f36
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 7 deletions.
2 changes: 1 addition & 1 deletion SubscribePlugin/lib/Foswiki/Plugins/SubscribePlugin.pm
Expand Up @@ -194,7 +194,7 @@ sub _template_text {
my $def = shift;
my $t = '';

if ( $_[0] =~ m/^(text|icon)$/ ) {
if ( $_[0] && $_[0] =~ m/^(text|icon)$/ ) {
$t = substr( $_[0], 0, 1 );
}

Expand Down
13 changes: 11 additions & 2 deletions UnitTestContrib/test/unit/RobustnessTests.pm
Expand Up @@ -137,8 +137,17 @@ sub test_sanitizeAttachmentName {
$crap .= $c if $c =~ m/$Foswiki::cfg{NameFilter}/;
}

#$this->assert_num_equals(80, length($crap));
$this->assert_num_equals( 51, length($crap) );
my $hex = '';
foreach my $ch ( split( //, $crap ) ) {
$hex .=
( $ch lt "\x20" || $ch gt "\x7e" ) ? '\x' . unpack( "H2", $ch ) : $ch;
}

my $expecthex =
'\x00\x01\x02\x03\x04\x05\x06\x07\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f "#$%&\'*;<>?@[\]^`|~';
$this->assert_str_equals( $expecthex, $hex,
"Expected: ($expecthex)\n Got: ($hex)\nHas {NameFilter} changed?" );
$this->assert_num_equals( 52, length($crap) );
my $x = $crap =~ m/ / ? '_' : '';
$this->assert_str_equals( "pick_me${x}pick_me",
_sanitize("pick me${crap}pick me") );
Expand Down
8 changes: 4 additions & 4 deletions core/locale/it.po
Expand Up @@ -7,10 +7,10 @@ msgstr ""
"Project-Id-Version: it\n"
"Report-Msgid-Bugs-To: foswiki-svn@lists.sourceforge.net\n"
"POT-Creation-Date: YEAR-MO-DA HO:MI+ZONE\n"
"PO-Revision-Date: 2015-06-15 18:14+0200\n"
"PO-Revision-Date: 2015-07-22 06:57+0200\n"
"Last-Translator: Guido Brugnara <gdo@leader.it>\n"
"Language-Team: Italian <http://translate.foswiki.org/projects/foswiki/"
"distribution-master/it/>\n"
"Language-Team: Italian <http://translate.foswiki.org/projects/foswiki"
"/distribution-master/it/>\n"
"Language: it\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
Expand Down Expand Up @@ -3034,7 +3034,7 @@ msgstr ""
#: core/lib/Foswiki/UI/Save.pm:660 core/lib/Foswiki/UI/Save.pm:699
#: core/lib/Foswiki/UI/Save.pm:729 core/lib/Foswiki/UI/Upload.pm:229
msgid "Operation %1 failed with an internal error"
msgstr ""
msgstr "Operazione %1 fallita con un errore interno"

#: core/templates/renamedelete.tmpl:23
msgid "Optionally change attachment name:"
Expand Down

0 comments on commit 34c1f36

Please sign in to comment.