summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xbin/efa5
-rw-r--r--lib/Travel/Routing/DE/EFA.pm6
2 files changed, 7 insertions, 4 deletions
diff --git a/bin/efa b/bin/efa
index 03d99c7..53d5398 100755
--- a/bin/efa
+++ b/bin/efa
@@ -85,8 +85,9 @@ sub handle_efa_exception {
if ( $e->isa('Travel::Routing::DE::EFA::Exception::Setup') ) {
if ( $e->message ) {
printf STDERR (
- "User error: %s (option '%s'): %s\n",
- $e->description, $e->option, $e->message
+ "User error: %s (option '%s'): %s%s\n",
+ $e->description, $e->option, $e->message,
+ $e->have ? q{ "} . $e->have . q{"} : q{},
);
}
else {
diff --git a/lib/Travel/Routing/DE/EFA.pm b/lib/Travel/Routing/DE/EFA.pm
index 32502fa..a89bbb1 100644
--- a/lib/Travel/Routing/DE/EFA.pm
+++ b/lib/Travel/Routing/DE/EFA.pm
@@ -839,13 +839,15 @@ sub check_ambiguous_xml {
if ( $s_place eq 'notidentified' ) {
Travel::Routing::DE::EFA::Exception::Setup->throw(
option => 'place',
- error => 'unknown place (typo?)'
+ error => 'unknown place',
+ have => ( $e_place->findnodes($xp_place_input) )[0]->textContent,
);
}
if ( $s_name eq 'notidentified' ) {
Travel::Routing::DE::EFA::Exception::Setup->throw(
option => 'name',
- error => 'unknown name (typo?)'
+ error => 'unknown name',
+ have => ( $e_name->findnodes($xp_name_input) )[0]->textContent,
);
}