Version 5.0.14
This commit is contained in:
1 parent
5efe744c5f
commit
dbd774b30c
364 files changed
+7048
-1377
No files matched your search
@@ -127,7 +127,7 @@ class Badge extends Model
|
||||
{
|
||||
$obj = parent::constructFromData( $data, $updateMultitonStoreIfExists );
|
||||
|
||||
if ( isset( $obj->recognize ) and ! empty( $obj->recognize ) )
|
||||
if ( isset( $obj->recognize ) and ! empty( $obj->recognize ) and is_numeric( $obj->recognize ) )
|
||||
{
|
||||
try
|
||||
{
|
||||
|
||||
@@ -361,7 +361,7 @@ class Approval extends ActiveRecord
|
||||
}
|
||||
if( $item->canHide() )
|
||||
{
|
||||
$actions['hide'] = $item->url()->setQueryString( array( 'do' => 'moderate', 'action' => 'hide', '_fromApproval' => 1 ) )->csrf();
|
||||
$actions['hide'] = $item->url()->setQueryString( array( 'do' => 'moderate', 'action' => 'hide' ) )->csrf();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -342,18 +342,6 @@ class Conversation extends Item
|
||||
} );
|
||||
}
|
||||
}
|
||||
else if ( $k == 'content' )
|
||||
{
|
||||
if( isset( Request::i()->to ) and Request::i()->to )
|
||||
{
|
||||
$v->options['autoSaveKey'] = 'newMessageTo-' . Request::i()->to;
|
||||
}
|
||||
else
|
||||
{
|
||||
/* Ensure that the autosave doesn't populate the editor witha previous PM which may be sent by accident */
|
||||
$v->options['autoSaveKey'] = 'newMessageTo-' . mt_rand();
|
||||
}
|
||||
}
|
||||
|
||||
$return[ $k ] = $v;
|
||||
}
|
||||
|
||||
@@ -17,6 +17,7 @@ use InvalidArgumentException;
|
||||
use IPS\Application;
|
||||
use IPS\Content;
|
||||
use IPS\Content\Comment;
|
||||
use IPS\Content\Hideable;
|
||||
use IPS\Content\Item;
|
||||
use IPS\Content\ReadMarkers;
|
||||
use IPS\core\Reports\Comment as ReportComment;
|
||||
@@ -773,7 +774,7 @@ class Report extends Item
|
||||
}
|
||||
|
||||
/* Is automatic moderation supported for this content type? */
|
||||
if ( !IPS::classUsesTrait( $reportedContent, 'IPS\Content\hideable' ) )
|
||||
if ( !IPS::classUsesTrait( $reportedContent, Hideable::class ) )
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
@@ -413,7 +413,8 @@ class Stream extends Model
|
||||
$classes = array();
|
||||
$classToggles = array();
|
||||
|
||||
foreach( SearchContent::searchableClasses() as $class )
|
||||
$memberToCheck = ( Dispatcher::hasInstance() and Dispatcher::i()->controllerLocation == 'admin' ) ? false : Member::loggedIn();
|
||||
foreach( SearchContent::searchableClasses( $memberToCheck ) as $class )
|
||||
{
|
||||
if( in_array( 'IPS\Content\Item', class_parents( $class ) ) AND isset( $class::$databaseColumnMap['date'] ) )
|
||||
{
|
||||
@@ -1262,7 +1263,7 @@ class Stream extends Model
|
||||
}
|
||||
else
|
||||
{
|
||||
foreach( SearchContent::searchableClasses() as $class )
|
||||
foreach( SearchContent::searchableClasses( $member ?? false ) as $class )
|
||||
{
|
||||
if ( in_array( 'IPS\Content\Item', class_parents( $class ) ) )
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user