소스 검색

Remove use of "rel" in function getUserPathById

jmontoyaa 9 년 전
부모
커밋
53a47e5f2f
2개의 변경된 파일2개의 추가작업 그리고 6개의 파일을 삭제
  1. 1 4
      main/inc/lib/usermanager.lib.php
  2. 1 2
      src/Chamilo/CoreBundle/Component/Editor/Driver/PersonalDriver.php

+ 1 - 4
main/inc/lib/usermanager.lib.php

@@ -1425,7 +1425,7 @@ class UserManager
      * function will attempt to create it. Probably not the right place to do it
      * function will attempt to create it. Probably not the right place to do it
      * but at least it avoids headaches in many other places.
      * but at least it avoids headaches in many other places.
      * @param   integer $id User ID
      * @param   integer $id User ID
-     * @param   string  $type Type of path to return (can be 'system', 'web', 'rel', 'last')
+     * @param   string  $type Type of path to return (can be 'system', 'web', 'last')
      * @return  string  User folder path (i.e. /var/www/chamilo/app/upload/users/1/1/)
      * @return  string  User folder path (i.e. /var/www/chamilo/app/upload/users/1/1/)
      */
      */
     public static function getUserPathById($id, $type)
     public static function getUserPathById($id, $type)
@@ -1459,9 +1459,6 @@ class UserManager
             case 'web': // Base: absolute web path.
             case 'web': // Base: absolute web path.
                 $userPath = api_get_path(WEB_UPLOAD_PATH).$userPath;
                 $userPath = api_get_path(WEB_UPLOAD_PATH).$userPath;
                 break;
                 break;
-            case 'rel': // Relative to the document root (e.g. app/upload/users/1/13/)
-                $userPath = api_get_path(REL_UPLOAD_PATH).$userPath;
-                break;
             case 'last': // Only the last part starting with users/
             case 'last': // Only the last part starting with users/
                 break;
                 break;
         }
         }

+ 1 - 2
src/Chamilo/CoreBundle/Component/Editor/Driver/PersonalDriver.php

@@ -44,8 +44,7 @@ class PersonalDriver extends Driver implements DriverInterface
 
 
                 // Adding user personal files
                 // Adding user personal files
                 $dir = \UserManager::getUserPathById($userId, 'system');
                 $dir = \UserManager::getUserPathById($userId, 'system');
-
-                $dirWeb = \UserManager::getUserPathById($userId, 'rel');
+                $dirWeb = \UserManager::getUserPathById($userId, 'web');
 
 
                 $driver = array(
                 $driver = array(
                     'driver' => 'PersonalDriver',
                     'driver' => 'PersonalDriver',