Version 4.5.0

This commit is contained in:
Neo committed 2025-12-19 05:51:58 -08:00
1 parent 1a0c7fd3c2
commit f79dcf067a
3791 files changed
+248032 -76372

No files matched your search

+32 -32
View File
@@ -11,7 +11,7 @@
namespace IPS\core\setup\upg_101000;
/* 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;
@@ -42,7 +42,7 @@ class _Upgrade
}
}
if ( count( $templateIds ) )
if ( \count( $templateIds ) )
{
\IPS\Db::i()->delete( 'core_theme_templates', array( \IPS\Db::i()->in( 'template_id', $templateIds ) ) );
}
@@ -171,7 +171,7 @@ class _Upgrade
/* Init */
$perCycle = 500;
$did = 0;
$limit = intval( \IPS\Request::i()->extra );
$limit = \intval( \IPS\Request::i()->extra );
/* Because follow_id gets changed in the process, we have to copy data to a temporary table first */
if ( !$limit )
@@ -344,7 +344,7 @@ class _Upgrade
$columns[] = 'mail_groups';
}
if( count( $columns ) )
if( \count( $columns ) )
{
\IPS\Db::i()->dropColumn( 'core_bulk_mail', $columns );
}
@@ -513,41 +513,41 @@ class _Upgrade
{
if ( $_k === 'widget_feed_status' )
{
if ( in_array( 'open', $_v ) and in_array( 'closed', $_v ) )
if ( \in_array( 'open', $_v ) and \in_array( 'closed', $_v ) )
{
$widgets[ $k ]['configuration']['widget_feed_status_locked'] = 'any';
}
else if ( in_array( 'open', $_v ) )
else if ( \in_array( 'open', $_v ) )
{
$widgets[ $k ]['configuration']['widget_feed_status_locked'] = 'open';
}
else if ( in_array( 'closed', $_v ) )
else if ( \in_array( 'closed', $_v ) )
{
$widgets[ $k ]['configuration']['widget_feed_status_locked'] = 'closed';
}
if ( in_array( 'pinned', $_v ) and in_array( 'notpinned', $_v ) )
if ( \in_array( 'pinned', $_v ) and \in_array( 'notpinned', $_v ) )
{
$widgets[ $k ]['configuration']['widget_feed_status_pinned'] = 'any';
}
else if ( in_array( 'pinned', $_v ) )
else if ( \in_array( 'pinned', $_v ) )
{
$widgets[ $k ]['configuration']['widget_feed_status_pinned'] = 'open';
}
else if ( in_array( 'notpinned', $_v ) )
else if ( \in_array( 'notpinned', $_v ) )
{
$widgets[ $k ]['configuration']['widget_feed_status_pinned'] = 'closed';
}
if ( in_array( 'featured', $_v ) and in_array( 'notfeatured', $_v ) )
if ( \in_array( 'featured', $_v ) and \in_array( 'notfeatured', $_v ) )
{
$widgets[ $k ]['configuration']['widget_feed_status_pinned'] = 'any';
}
else if ( in_array( 'featured', $_v ) )
else if ( \in_array( 'featured', $_v ) )
{
$widgets[ $k ]['configuration']['widget_feed_status_pinned'] = 'featured';
}
else if ( in_array( 'notfeatured', $_v ) )
else if ( \in_array( 'notfeatured', $_v ) )
{
$widgets[ $k ]['configuration']['widget_feed_status_pinned'] = 'notfeatured';
}
@@ -568,7 +568,7 @@ class _Upgrade
$config = array();
foreach ( $widgets[ $k ]['configuration'] as $_k => $_v )
{
if ( in_array( $_k, array( 'tfb_show', 'tfb_sort_dir', 'tfb_use_perms', 'tfb_topic_status' ) ) )
if ( \in_array( $_k, array( 'tfb_show', 'tfb_sort_dir', 'tfb_use_perms', 'tfb_topic_status' ) ) )
{
$_k = str_replace( 'tfb_', 'widget_feed', $_k );
}
@@ -579,41 +579,41 @@ class _Upgrade
if ( $_k == 'widget_feed_topic_status' )
{
if ( in_array( 'open', $_v ) and in_array( 'closed', $_v ) )
if ( \in_array( 'open', $_v ) and \in_array( 'closed', $_v ) )
{
$widgets[ $k ]['configuration']['widget_feed_item_status_locked'] = 'any';
}
else if ( in_array( 'open', $_v ) )
else if ( \in_array( 'open', $_v ) )
{
$widgets[ $k ]['configuration']['widget_feed_item_status_locked'] = 'open';
}
else if ( in_array( 'closed', $_v ) )
else if ( \in_array( 'closed', $_v ) )
{
$widgets[ $k ]['configuration']['widget_feed_item_status_locked'] = 'closed';
}
if ( in_array( 'pinned', $_v ) and in_array( 'notpinned', $_v ) )
if ( \in_array( 'pinned', $_v ) and \in_array( 'notpinned', $_v ) )
{
$widgets[ $k ]['configuration']['widget_feed_item_status_pinned'] = 'any';
}
else if ( in_array( 'pinned', $_v ) )
else if ( \in_array( 'pinned', $_v ) )
{
$widgets[ $k ]['configuration']['widget_feed_item_status_pinned'] = 'open';
}
else if ( in_array( 'notpinned', $_v ) )
else if ( \in_array( 'notpinned', $_v ) )
{
$widgets[ $k ]['configuration']['widget_feed_item_status_pinned'] = 'closed';
}
if ( in_array( 'featured', $_v ) and in_array( 'notfeatured', $_v ) )
if ( \in_array( 'featured', $_v ) and \in_array( 'notfeatured', $_v ) )
{
$widgets[ $k ]['configuration']['widget_feed_item_status_pinned'] = 'any';
}
else if ( in_array( 'featured', $_v ) )
else if ( \in_array( 'featured', $_v ) )
{
$widgets[ $k ]['configuration']['widget_feed_item_status_pinned'] = 'featured';
}
else if ( in_array( 'notfeatured', $_v ) )
else if ( \in_array( 'notfeatured', $_v ) )
{
$widgets[ $k ]['configuration']['widget_feed_item_status_pinned'] = 'notfeatured';
}
@@ -643,41 +643,41 @@ class _Upgrade
if ( $_k === 'widget_feed_status' )
{
if ( in_array( 'open', $_v ) and in_array( 'closed', $_v ) )
if ( \in_array( 'open', $_v ) and \in_array( 'closed', $_v ) )
{
$widgets[ $k ]['configuration']['widget_feed_status_locked'] = 'any';
}
else if ( in_array( 'open', $_v ) )
else if ( \in_array( 'open', $_v ) )
{
$widgets[ $k ]['configuration']['widget_feed_status_locked'] = 'open';
}
else if ( in_array( 'closed', $_v ) )
else if ( \in_array( 'closed', $_v ) )
{
$widgets[ $k ]['configuration']['widget_feed_status_locked'] = 'closed';
}
if ( in_array( 'pinned', $_v ) and in_array( 'notpinned', $_v ) )
if ( \in_array( 'pinned', $_v ) and \in_array( 'notpinned', $_v ) )
{
$widgets[ $k ]['configuration']['widget_feed_status_pinned'] = 'any';
}
else if ( in_array( 'pinned', $_v ) )
else if ( \in_array( 'pinned', $_v ) )
{
$widgets[ $k ]['configuration']['widget_feed_status_pinned'] = 'open';
}
else if ( in_array( 'notpinned', $_v ) )
else if ( \in_array( 'notpinned', $_v ) )
{
$widgets[ $k ]['configuration']['widget_feed_status_pinned'] = 'closed';
}
if ( in_array( 'featured', $_v ) and in_array( 'notfeatured', $_v ) )
if ( \in_array( 'featured', $_v ) and \in_array( 'notfeatured', $_v ) )
{
$widgets[ $k ]['configuration']['widget_feed_status_pinned'] = 'any';
}
else if ( in_array( 'featured', $_v ) )
else if ( \in_array( 'featured', $_v ) )
{
$widgets[ $k ]['configuration']['widget_feed_status_pinned'] = 'featured';
}
else if ( in_array( 'notfeatured', $_v ) )
else if ( \in_array( 'notfeatured', $_v ) )
{
$widgets[ $k ]['configuration']['widget_feed_status_pinned'] = 'notfeatured';
}