issue84, do not further process RPC request, if no action has been specified
authorAndreas Unterkircher <unki@netshadow.at>
Sun, 30 Dec 2007 14:49:20 +0000 (15:49 +0100)
committerAndreas Unterkircher <unki@netshadow.at>
Sun, 30 Dec 2007 14:49:20 +0000 (15:49 +0100)
rpc.php

diff --git a/rpc.php b/rpc.php
index bdb7004ad6de1d6a03ec68c1760077517aa8e67d..4a8ca7c0e6a5f2af35dabed57d3f976e5bbd6b36 100644 (file)
--- a/rpc.php
+++ b/rpc.php
@@ -40,6 +40,12 @@ class PHPFSPOT_RPC {
 
       $fspot = new PHPFSPOT();
 
+      /* if no action is specified, no need to further process this
+       * function here.
+       */
+      if(!isset($_GET['action']))
+         return;
+
       switch($_GET['action']) {
          case 'showphoto':
             if(isset($_GET['id']) && is_numeric($_GET['id'])) {
@@ -142,7 +148,7 @@ class PHPFSPOT_RPC {
 
    } // process_ajax_request();
 
-}
+} // class PHPFSPOT_RPC
 
 $rpc = new PHPFSPOT_RPC();
 $rpc->process_ajax_request();