]> dev.renevier.net Git - syj.git/blobdiff - application/controllers/PathController.php
do not fail when client uses a proxy
[syj.git] / application / controllers / PathController.php
index bb969e82c8ed6b15888a6cf9de01adc0510c7a4e..48a22befd43930ef1d0f6a8036e28524c1ea347d 100644 (file)
@@ -13,7 +13,7 @@ class PathController extends Zend_Controller_Action
             throw new Syj_Exception_Request();
         }
         $path->creator = $user;
-        $path->creatorIp = $this->getRequest()->getClientIp(true);
+        $path->creatorIp = trim(end(split(',', $this->getRequest()->getClientIp(true))));
 
         $this->save($path, $formData);
         $data = array('redirect' => "idx/" . (string)$path->id);