in reply to Missing right curly or square bracket
I think there is a closing brace missing at the very end of your code. Reason: At the beginning of this while the filehandle $lscore_fh is defined and set.
while (my $currentlist_row = $currentlist_csv->getline_hr($currentlist +_fh)) { my $lscore_fh; if (exists($lscore{$currentlist_row->{FacID}})) { $lscore_fh = $fh{$currentlist_row->{FacID}} //= do { open my $f, '>:utf8', $lscore{$currentlist_row->{FacID}}; $f; }; } else { $lscore_fh = $fh{__LSCORE__} //= do { open my $f, '>:utf8', $lscore_fallback_file; $f; }; }
The filhandle is still used at the very end of your code, so it has to be within the while loop. So the loop only closes at the very end.
|
|---|