X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=SL%2FShopConnector%2FShopware.pm;h=a777ddfb2e38ab8eae2b2d0fb324a79688d5c5b5;hb=ddec2dcd58e019a3386dce322985da9bec0c9501;hp=7e879bfefe7aa0292a2e02e219ad40e82e0e4b69;hpb=457e1237959ddf06c2198e2fba1768adc8053840;p=kivitendo-erp.git diff --git a/SL/ShopConnector/Shopware.pm b/SL/ShopConnector/Shopware.pm index 7e879bfef..a777ddfb2 100644 --- a/SL/ShopConnector/Shopware.pm +++ b/SL/ShopConnector/Shopware.pm @@ -190,7 +190,8 @@ sub map_data_to_shoporder { my %payment_ids_methods = ( # shopware_paymentId => kivitendo_payment_id ); - my $default_payment_id = SL::DB::Manager::PaymentTerm->get_first()->id || undef; + my $default_payment = SL::DB::Manager::PaymentTerm->get_first(); + my $default_payment_id = $default_payment ? $default_payment->id : undef; # Mapping to table shoporders. See http://community.shopware.com/_detail_1690.html#GET_.28Liste.29 my %columns = ( amount => $import->{data}->{invoiceAmount},