Version 5.0.0 beta 1

This commit is contained in:
Neo committed 2025-12-19 16:27:35 -08:00
1 parent 25ddeb65d6
commit 15c7beabc5
6736 files changed
+627902 -497943

No files matched your search

+11 -6
View File
@@ -11,25 +11,30 @@
namespace IPS\Application;
/* To prevent PHP errors (extending class does not exist) revealing path */
if ( !\defined( '\IPS\SUITE_UNIQUE_KEY' ) )
use RecursiveFilterIterator;
use function defined;
use function in_array;
if ( !defined( '\IPS\SUITE_UNIQUE_KEY' ) )
{
header( ( isset( $_SERVER['SERVER_PROTOCOL'] ) ? $_SERVER['SERVER_PROTOCOL'] : 'HTTP/1.0' ) . ' 403 Forbidden' );
header( ( $_SERVER['SERVER_PROTOCOL'] ?? 'HTTP/1.0' ) . ' 403 Forbidden' );
exit;
}
/**
* @brief Custom filter iterator for application building
*/
class _BuilderFilter extends \RecursiveFilterIterator
class BuilderFilter extends RecursiveFilterIterator
{
/**
* Accept the member
*
* @return bool
*/
public function accept()
public function accept(): bool
{
return !( $this->isDir() && \in_array( $this->getFilename(), $this->getDirectoriesToIgnore() ) );
return !( $this->isDir() && in_array( $this->getFilename(), $this->getDirectoriesToIgnore() ) );
}
/**
@@ -37,7 +42,7 @@ class _BuilderFilter extends \RecursiveFilterIterator
*
* @return array
*/
protected function getDirectoriesToIgnore()
protected function getDirectoriesToIgnore(): array
{
return array(
'.git',