summaryrefslogtreecommitdiff
path: root/lib/Travelynx/Command/traewelling.pm
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Travelynx/Command/traewelling.pm')
-rw-r--r--lib/Travelynx/Command/traewelling.pm11
1 files changed, 9 insertions, 2 deletions
diff --git a/lib/Travelynx/Command/traewelling.pm b/lib/Travelynx/Command/traewelling.pm
index 5967b28..d8eeaef 100644
--- a/lib/Travelynx/Command/traewelling.pm
+++ b/lib/Travelynx/Command/traewelling.pm
@@ -126,8 +126,15 @@ sub run {
if ( not $direction or $direction eq 'pull' ) {
$report .= ",pull_runtime_seconds=${trwl_pull_duration}";
}
- $self->app->ua->post_p( $self->app->config->{influxdb}->{url},
- "traewelling ${report}" )->wait;
+ if ( $self->app->mode eq 'development' ) {
+ $self->app->log->debug( 'POST '
+ . $self->app->config->{influxdb}->{url}
+ . " traewelling ${report}" );
+ }
+ else {
+ $self->app->ua->post_p( $self->app->config->{influxdb}->{url},
+ "traewelling ${report}" )->wait;
+ }
}
}