Skip to content

Commit 4ff6196

Browse files
[DCOM-66][PR-55] Changed obsolete function ClassLoader::fileExistsInIncludePath() to native PHP implementation stream_resolve_include_path().
1 parent 82a5a2a commit 4ff6196

File tree

2 files changed

+5
-10
lines changed

2 files changed

+5
-10
lines changed

UPGRADE_TO_2_2

+4
Original file line numberDiff line numberDiff line change
@@ -55,3 +55,7 @@ updating your project from Doctrine Common 2.1 to 2.2:
5555
- Added support to MemcachedCache
5656

5757
- Added support to WincacheCache
58+
59+
## ClassLoader Changes
60+
61+
- ClassLoader::fileExistsInIncludePath() no longer exists. Use the native stream_resolve_include_path() PHP function

lib/Doctrine/Common/ClassLoader.php

+1-10
Original file line numberDiff line numberDiff line change
@@ -184,7 +184,7 @@ public function canLoadClass($className)
184184
return file_exists($this->includePath . DIRECTORY_SEPARATOR . $file);
185185
}
186186

187-
return (false !== stream_resolve_include_path($file));//self::fileExistsInIncludePath($file);
187+
return (false !== stream_resolve_include_path($file));
188188
}
189189

190190
/**
@@ -259,13 +259,4 @@ public static function getClassLoader($className)
259259

260260
return null;
261261
}
262-
263-
/**
264-
* @param string $file The file relative path.
265-
* @return boolean Whether file exists in include_path.
266-
*/
267-
/*public static function fileExistsInIncludePath($file)
268-
{
269-
return (false !== stream_resolve_include_path($file));
270-
}*/
271262
}

0 commit comments

Comments
 (0)