[feature/module_services] Let generate_migrations_data handle new modules
This commit is contained in:
47
develop/phpbb_functions.php
Normal file
47
develop/phpbb_functions.php
Normal file
@@ -0,0 +1,47 @@
|
||||
<?php
|
||||
/**
|
||||
*
|
||||
* @package Board3 Portal v2.1
|
||||
* @copyright (c) 2013 Board3 Group ( www.board3.de )
|
||||
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
|
||||
*
|
||||
*/
|
||||
|
||||
namespace phpbb\di\extension;
|
||||
|
||||
if (!function_exists('realpath'))
|
||||
{
|
||||
/**
|
||||
* A wrapper for realpath
|
||||
* @ignore
|
||||
*/
|
||||
function phpbb_realpath($path)
|
||||
{
|
||||
return phpbb_own_realpath($path);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
/**
|
||||
* A wrapper for realpath
|
||||
*/
|
||||
function phpbb_realpath($path)
|
||||
{
|
||||
$realpath = realpath($path);
|
||||
|
||||
// Strangely there are provider not disabling realpath but returning strange values. :o
|
||||
// We at least try to cope with them.
|
||||
if ($realpath === $path || $realpath === false)
|
||||
{
|
||||
return phpbb_own_realpath($path);
|
||||
}
|
||||
|
||||
// Check for DIRECTORY_SEPARATOR at the end (and remove it!)
|
||||
if (substr($realpath, -1) == DIRECTORY_SEPARATOR)
|
||||
{
|
||||
$realpath = substr($realpath, 0, -1);
|
||||
}
|
||||
|
||||
return $realpath;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user