Permalink
Browse files

Patched to work better with CI 2. Input vrs Security.

  • Loading branch information...
1 parent b6df2b5 commit e86ecc977994fd5cc16057ebaa4dfe3724c9c323 Phil Sturgeon committed Sep 1, 2010
Showing with 9 additions and 1 deletion.
  1. +9 −1 application/libraries/REST_Controller.php
@@ -479,7 +479,15 @@ public function delete($key = NULL, $xss_clean = TRUE)
private function _xss_clean($val, $bool)
{
- return $bool ? $this->input->xss_clean($val) : $val;
+ if(CI_VERSION < 2)
+ {
+ return $bool ? $this->input->xss_clean($val) : $val;
+ }
+
+ else
+ {
+ return $bool ? $this->security->xss_clean($val) : $val;
+ }
}
// SECURITY FUNCTIONS ---------------------------------------------------------

0 comments on commit e86ecc9

Please sign in to comment.