From 6234851ff7e3d67b0046e5a03896c2b67cc25b62 Mon Sep 17 00:00:00 2001 From: Carl Bennett Date: Sun, 9 Apr 2017 11:43:09 +0000 Subject: [PATCH] Add getRoutes function that copies the array --- src/libraries/Router.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/libraries/Router.php b/src/libraries/Router.php index dedad01..1231a88 100644 --- a/src/libraries/Router.php +++ b/src/libraries/Router.php @@ -212,6 +212,10 @@ public function getRequestURI() { return $this->requestURI; } + public function getRoutes() { + return clone (object) $this->routes; + } + public function route() { $path = $this->getRequestPathString(true); $target = null;