Version 4.2.0

This commit is contained in:
Neo committed 2025-12-19 05:44:59 -08:00
1 parent 0dc2aee5ed
commit 96997ddd8e
2074 files changed
+125454 -55780

No files matched your search

+25 -7
View File
@@ -1,12 +1,11 @@
<?php
/**
* @brief Installer
* @author <a href='http://www.invisionpower.com'>Invision Power Services, Inc.</a>
* @copyright (c) 2001 - 2016 Invision Power Services, Inc.
* @license http://www.invisionpower.com/legal/standards/
* @package IPS Community Suite
* @author <a href='https://www.invisioncommunity.com'>Invision Power Services, Inc.</a>
* @copyright (c) Invision Power Services, Inc.
* @license https://www.invisioncommunity.com/legal/standards/
* @package Invision Community
* @since 3 Apr 2013
* @version SVN_VERSION_NUMBER
*/
namespace IPS\core\Setup;
@@ -113,7 +112,6 @@ class _Install
'message' => \IPS\Member::loggedIn()->language()->addToStack( 'requirements_mb_fail' ),
);
}
/* Extensions */
foreach ( array(
@@ -150,6 +148,12 @@ class _Install
}
}
}
/* Recommend GD freetype */
if( extension_loaded('gd') AND !function_exists( 'imagettfbbox' ) )
{
$return['advice'][] = \IPS\Member::loggedIn()->language()->addToStack( 'requirements_missing_imagettfbbox' );
}
/* Memory Limit */
$_memoryLimit = @ini_get('memory_limit');
@@ -639,6 +643,7 @@ class _Install
{
\IPS\Settings::i()->member_group = 4;
$member = new \IPS\Member;
$member->pp_photo_type = '';
$member->name = $this->adminName;
$member->email = $this->adminEmail;
$member->ip_address = \IPS\Request::i()->ipAddress();
@@ -872,7 +877,7 @@ class _Install
\IPS\Log::log( $e, 'install_error' );
}
/* Insert default emoticons */
/* Insert default emoticons and reaction */
if( $app == 'core' )
{
$setId = md5( uniqid() );
@@ -903,6 +908,19 @@ class _Install
{
\IPS\Db::i()->insert( 'core_emoticons', $inserts );
}
$position = 0;
foreach( array( 'like', 'thanks', 'haha', 'confused', 'sad' ) AS $reaction )
{
$fileObj = \IPS\File::create( 'core_Reaction', "react_{$reaction}.png", file_get_contents( \IPS\ROOT_PATH . '/' . \IPS\CP_DIRECTORY . "/install/reaction/react_{$reaction}.png" ), 'reactions', FALSE, NULL, FALSE );
$id = \IPS\Db::i()->insert( 'core_reactions', array(
'reaction_value' => ( in_array( $reaction, array( 'confused', 'sad' ) ) ) ? 0 : 1,
'reaction_icon' => (string) $fileObj,
'reaction_position' => ++$position,
'reaction_enabled' => 1,
) );
\IPS\Lang::saveCustom( 'core', 'reaction_title_' . $id, ucwords( $reaction ) );
}
}
} );
}
+6 -11
View File
@@ -1,12 +1,11 @@
<?php
/**
* @brief Upgrader
* @author <a href='http://www.invisionpower.com'>Invision Power Services, Inc.</a>
* @copyright (c) 2001 - 2016 Invision Power Services, Inc.
* @license http://www.invisionpower.com/legal/standards/
* @package IPS Community Suite
* @author <a href='https://www.invisioncommunity.com'>Invision Power Services, Inc.</a>
* @copyright (c) Invision Power Services, Inc.
* @license https://www.invisioncommunity.com/legal/standards/
* @package Invision Community
* @since 21 May 2014
* @version SVN_VERSION_NUMBER
* @todo MAKE DATABASE CHECK RUN BEFORE EVERYTHING ELSE
*/
@@ -36,10 +35,11 @@ class _Upgrade
/* MySQL Requirements */
$return = array_merge_recursive( $return, static::mysqlRequirements( ) );
$writeablesKey = \IPS\Member::loggedIn()->language()->addToStack('requirements_file_system');
/* Writeables */
if( \IPS\Db::i()->checkForTable('core_file_storage') )
{
$writeablesKey = \IPS\Member::loggedIn()->language()->addToStack('requirements_file_system');
$fileSystemItems = array();
foreach ( \IPS\Application::allExtensions( 'core', 'FileStorage', FALSE ) as $k => $v )
@@ -417,11 +417,6 @@ class _Upgrade
$fetched = array( 'count' => $fetched['count'] );
}
if( isset( \IPS\Request::i()->mr_continue ) AND \IPS\Request::i()->mr_continue )
{
$fetched = array( 'count' => $fetched['count'] );
}
$extra['lastSqlId'] = $_SESSION['lastJsonIndex'];
\IPS\Log::debug( (int) $fetched['count'] . ' queries run, last ID ' . $_SESSION['lastJsonIndex'], 'upgrade' );