From 8ad3a60e282dc36dd0738751ff714e1d04abdd8f Mon Sep 17 00:00:00 2001 From: =?utf8?q?Bernd=20Ble=C3=9Fmann?= Date: Fri, 16 Aug 2013 17:11:59 +0200 Subject: [PATCH] Code-Vereinfachung --- SL/Helper/Csv/Dispatcher.pm | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/SL/Helper/Csv/Dispatcher.pm b/SL/Helper/Csv/Dispatcher.pm index a744892c1..a08a63397 100644 --- a/SL/Helper/Csv/Dispatcher.pm +++ b/SL/Helper/Csv/Dispatcher.pm @@ -106,19 +106,13 @@ sub is_known { sub parse_profile { my ($self, %params) = @_; - my $profile; - my $class; my @specs; + my $csv_profile = $self->_csv->profile; my $i = 0; foreach my $header (@{ $self->_csv->header }) { - if ($self->_csv->profile) { - $profile = $self->_csv->profile->[$i]->{profile}; - $class = $self->_csv->profile->[$i]->{class}; - } - - my $spec = $self->_parse_profile(profile => $profile, - class => $class, + my $spec = $self->_parse_profile(profile => $csv_profile->[$i]->{profile}, + class => $csv_profile->[$i]->{class}, header => $header); push @specs, $spec; $i++; -- 2.20.1