]> source.dussan.org Git - nextcloud-server.git/commitdiff
fix chmodr
authorRobin Appelman <icewind1991@gmail.com>
Sun, 24 Apr 2011 13:23:18 +0000 (15:23 +0200)
committerRobin Appelman <icewind1991@gmail.com>
Sun, 24 Apr 2011 13:23:18 +0000 (15:23 +0200)
lib/helper.php

index c141d6f04996a15f395d95bfc9e88eeaa4bba541..009e961397b9d970d6360c4aa5d4072a1a265861 100644 (file)
@@ -166,7 +166,7 @@ class OC_HELPER {
         *
         * Makes 2048 to 2 kB.
         */
-       function chmodr($path, $filemode) {
+       static function chmodr($path, $filemode) {
                if (!is_dir($path))
                        return chmod($path, $filemode);
                $dh = opendir($path);
@@ -177,7 +177,7 @@ class OC_HELPER {
                                        return FALSE;
                                elseif(!is_dir($fullpath) && !chmod($fullpath, $filemode))
                                                return FALSE;
-                               elseif(!chmodr($fullpath, $filemode))
+                               elseif(!self::chmodr($fullpath, $filemode))
                                        return FALSE;
                        }
                }