From 7eadf7cfd80176ab9b74c9c6a55c28db0f43fa88 Mon Sep 17 00:00:00 2001 From: Frédéric Guillot Date: Sun, 9 Nov 2014 20:04:27 -0500 Subject: Start templates cleanup and reorganisation --- app/Core/Request.php | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'app/Core/Request.php') diff --git a/app/Core/Request.php b/app/Core/Request.php index a4c426f0..1b643208 100644 --- a/app/Core/Request.php +++ b/app/Core/Request.php @@ -75,6 +75,17 @@ class Request return file_get_contents('php://input'); } + /** + * Get the Json request body + * + * @access public + * @return array + */ + public function getJson() + { + return json_decode($this->getBody(), true); + } + /** * Get the content of an uploaded file * -- cgit v1.2.3