From c6086c615f99b1cd99fa1a7103a64d2d8a7c9e9f Mon Sep 17 00:00:00 2001
From: Ibnu Maksum <ibnumaksum@gmail.com>
Date: Mon, 26 Feb 2024 15:02:36 +0700
Subject: [PATCH] Error Info

---
 system/api.php         | 3 ---
 ui/ui/router-error.tpl | 7 +++++++
 2 files changed, 7 insertions(+), 3 deletions(-)

diff --git a/system/api.php b/system/api.php
index d923e73d..cbcccf9e 100644
--- a/system/api.php
+++ b/system/api.php
@@ -46,9 +46,6 @@ $req = _get('r');
 $token = _get('token');
 $routes = explode('/', $req);
 $handler = $routes[0];
-if ($handler == '') {
-    $handler = 'default';
-}
 
 if(empty($token)){
     showResult(false, Lang::T("Token is invalid"));
diff --git a/ui/ui/router-error.tpl b/ui/ui/router-error.tpl
index 344c0a46..f796a755 100644
--- a/ui/ui/router-error.tpl
+++ b/ui/ui/router-error.tpl
@@ -47,6 +47,13 @@
                             <br>
                             {$error_message}
                             <br>
+                            Mikrotik troubleshooting: <br>
+                            <ul>
+                                <li>Make sure you use API Port, Default 8728</li>
+                                <li>Make sure Username and Password are correct</li>
+                                <li>Make sure your hosting not blocking port to external</li>
+                                <li>Make sure your Mikrotik accessible from PHPNuxBill</li>
+                            </ul>
                         </div>
                         <div class="box-footer">
                             <div class="btn-group btn-group-justified" role="group" aria-label="...">