Commit ae24879b authored by Birte Kristina Friesel's avatar Birte Kristina Friesel
Browse files

EFA: Handle empty XML results (LibXML does not like them)

parent d87916ae
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -127,6 +127,13 @@ sub new {

	$self->{xml} = $response->decoded_content;

	if ( not $self->{xml} ) {

		# LibXML doesn't like empty documents
		$self->{errstr} = 'Server returned nothing (empty result)';
		return $self;
	}

	$self->{tree} = XML::LibXML->load_xml(
		string => $self->{xml},
	);