From 3d86c18e79cfffaf61fe76a6a9bc1ea90b7b9416 Mon Sep 17 00:00:00 2001 From: Damyan Ivanov Date: Sat, 19 Feb 2022 08:28:31 +0000 Subject: [PATCH] move sub declaration before usage --- lib/App/LazyShoppingList/API.pm | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/lib/App/LazyShoppingList/API.pm b/lib/App/LazyShoppingList/API.pm index 84e7fad..36f7e68 100644 --- a/lib/App/LazyShoppingList/API.pm +++ b/lib/App/LazyShoppingList/API.pm @@ -65,15 +65,15 @@ sub increment_lists_version($dbh) { return $g->lists_version; } -sub invalid_input($details = undef) { - return exception 400, - "Invalid input" . ( defined($details) ? " ($details)" : '' ); -} - sub exception($http_code, $text) { status $http_code; return { exception => $text }; } +sub invalid_input($details = undef) { + return exception 400, + "Invalid input" . ( defined($details) ? " ($details)" : '' ); +} + 1; -- 2.39.5