summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--cpanfile.snapshot24
-rwxr-xr-xlib/Travelynx/Controller/Profile.pm15
2 files changed, 27 insertions, 12 deletions
diff --git a/cpanfile.snapshot b/cpanfile.snapshot
index f8b30cc..570e304 100644
--- a/cpanfile.snapshot
+++ b/cpanfile.snapshot
@@ -2714,18 +2714,18 @@ DISTRIBUTIONS
TimeDate 1.21
requirements:
ExtUtils::MakeMaker 0
- Travel-Status-DE-DBRIS-0.18
- pathname: D/DE/DERF/Travel-Status-DE-DBRIS-0.18.tar.gz
- provides:
- Travel::Status::DE::DBRIS 0.18
- Travel::Status::DE::DBRIS::Formation 0.18
- Travel::Status::DE::DBRIS::Formation::Carriage 0.18
- Travel::Status::DE::DBRIS::Formation::Group 0.18
- Travel::Status::DE::DBRIS::Formation::Sector 0.18
- Travel::Status::DE::DBRIS::Journey 0.18
- Travel::Status::DE::DBRIS::JourneyAtStop 0.18
- Travel::Status::DE::DBRIS::Location 0.18
- Travel::Status::DE::DBRIS::Operators 0.18
+ Travel-Status-DE-DBRIS-0.19
+ pathname: D/DE/DERF/Travel-Status-DE-DBRIS-0.19.tar.gz
+ provides:
+ Travel::Status::DE::DBRIS 0.19
+ Travel::Status::DE::DBRIS::Formation 0.19
+ Travel::Status::DE::DBRIS::Formation::Carriage 0.19
+ Travel::Status::DE::DBRIS::Formation::Group 0.19
+ Travel::Status::DE::DBRIS::Formation::Sector 0.19
+ Travel::Status::DE::DBRIS::Journey 0.19
+ Travel::Status::DE::DBRIS::JourneyAtStop 0.19
+ Travel::Status::DE::DBRIS::Location 0.19
+ Travel::Status::DE::DBRIS::Operators 0.19
requirements:
Carp 0
Class::Accessor 0.16
diff --git a/lib/Travelynx/Controller/Profile.pm b/lib/Travelynx/Controller/Profile.pm
index 978e3f8..8f3a1b2 100755
--- a/lib/Travelynx/Controller/Profile.pm
+++ b/lib/Travelynx/Controller/Profile.pm
@@ -369,6 +369,21 @@ sub user_status {
return;
}
+ if ( not $ts =~ m{ ^ \d+ [.]? \d* $ }x ) {
+ $self->respond_to(
+ json => {
+ json => { error => 'bad request (invalid timestamp)' },
+ status => 400,
+ },
+ any => {
+ template => 'bad_request',
+ message => 'Invalid timestamp',
+ status => 400
+ }
+ );
+ return;
+ }
+
my $my_user;
my $relation;
my $inverse_relation;