summaryrefslogtreecommitdiff
path: root/httemplate/misc
diff options
context:
space:
mode:
authorivan <ivan>2004-05-28 11:33:21 +0000
committerivan <ivan>2004-05-28 11:33:21 +0000
commit038eaf525927a161e40577b2f2eec96c30523a6d (patch)
tree569b03f353ce6cf8feb613c3ba54dadecfe87910 /httemplate/misc
parent2e1a3719f1a9fb1f561d0eb4df349f3f03d66681 (diff)
not entirely sure why we're checking the filename at all... to catch empty form submissions?
Diffstat (limited to 'httemplate/misc')
-rw-r--r--httemplate/misc/upload-batch.cgi5
1 files changed, 3 insertions, 2 deletions
diff --git a/httemplate/misc/upload-batch.cgi b/httemplate/misc/upload-batch.cgi
index da5e41cbc..5d0150177 100644
--- a/httemplate/misc/upload-batch.cgi
+++ b/httemplate/misc/upload-batch.cgi
@@ -2,8 +2,9 @@
my $fh = $cgi->upload('batch_results');
my $filename = $cgi->param('batch_results');
- $filename =~ /^.*[\/\\]([^\/\\]+)$/ or die "unparsable filename: $filename\n";
- my $paybatch = $1;
+ $filename =~ /^(.*[\/\\])?([^\/\\]+)$/
+ or die "unparsable filename: $filename\n";
+ my $paybatch = $2;
my $error = defined($fh)
? FS::cust_pay_batch::import_results( {