Version 4.5.0
This commit is contained in:
1 parent
1a0c7fd3c2
commit
f79dcf067a
3791 files changed
+248032
-76372
No files matched your search
@@ -12,7 +12,7 @@
|
||||
namespace IPS\cms;
|
||||
|
||||
/* To prevent PHP errors (extending class does not exist) revealing path */
|
||||
if ( !defined( '\IPS\SUITE_UNIQUE_KEY' ) )
|
||||
if ( !\defined( '\IPS\SUITE_UNIQUE_KEY' ) )
|
||||
{
|
||||
header( ( isset( $_SERVER['SERVER_PROTOCOL'] ) ? $_SERVER['SERVER_PROTOCOL'] : 'HTTP/1.0' ) . ' 403 Forbidden' );
|
||||
exit;
|
||||
@@ -150,7 +150,7 @@ class _Media extends \IPS\Node\Model
|
||||
public static function getChildren( $folderId=0 )
|
||||
{
|
||||
$children = array();
|
||||
foreach( \IPS\Db::i()->select( '*', static::$databaseTable, array( 'media_parent=?', intval( $folderId ) ), 'media_filename ASC' ) as $child )
|
||||
foreach( \IPS\Db::i()->select( '*', static::$databaseTable, array( 'media_parent=?', \intval( $folderId ) ), 'media_filename ASC' ) as $child )
|
||||
{
|
||||
$children[ $child[ static::$databasePrefix . static::$databaseColumnId ] ] = static::load( $child[ static::$databasePrefix . static::$databaseColumnId ] );
|
||||
}
|
||||
@@ -214,8 +214,7 @@ class _Media extends \IPS\Node\Model
|
||||
|
||||
/**
|
||||
* [Node] Get buttons to display in tree
|
||||
* Example code explains return value
|
||||
* @endcode
|
||||
*
|
||||
* @param string $url Base URL
|
||||
* @param bool $subnode Is this a subnode?
|
||||
* @return array
|
||||
@@ -438,7 +437,7 @@ class _Media extends \IPS\Node\Model
|
||||
break;
|
||||
}
|
||||
|
||||
if ( ! in_array( $currentParent, $folders ) )
|
||||
if ( ! \in_array( $currentParent, $folders ) )
|
||||
{
|
||||
$folders[] = $currentParent;
|
||||
}
|
||||
@@ -473,6 +472,8 @@ class _Media extends \IPS\Node\Model
|
||||
/**
|
||||
* Import media from disk for designer's mode recursive method
|
||||
*
|
||||
* @param array $seen Files we've seen already
|
||||
* @param string $path Path to look in
|
||||
* @return void
|
||||
*/
|
||||
public static function importDesignersModeMediaRecurse( &$seen, $path )
|
||||
@@ -538,7 +539,7 @@ class _Media extends \IPS\Node\Model
|
||||
$filename = array_pop( $exploded );
|
||||
$folderId = 0;
|
||||
|
||||
if ( count( $exploded ) )
|
||||
if ( \count( $exploded ) )
|
||||
{
|
||||
$testDir = trim( implode( '/', $exploded ), '/' );
|
||||
try
|
||||
|
||||
Reference in new issue
Block a user