Skip to content

Commit

Permalink
MyBB 1.8.7 patch
Browse files Browse the repository at this point in the history
  • Loading branch information
Stefan-MyBB committed Mar 25, 2016
1 parent b7454e6 commit c7a8925
Show file tree
Hide file tree
Showing 8 changed files with 11 additions and 9 deletions.
2 changes: 1 addition & 1 deletion inc/cachehandlers/eaccelerator.php
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ function disconnect()
*
* @return string
*/
function size_of($name)
function size_of($name='')
{
global $lang;

Expand Down
2 changes: 1 addition & 1 deletion inc/cachehandlers/interface.php
Original file line number Diff line number Diff line change
Expand Up @@ -57,5 +57,5 @@ function disconnect();
*
* @return string
*/
function size_of($name);
function size_of($name='');
}
2 changes: 1 addition & 1 deletion inc/cachehandlers/memcache.php
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ function disconnect()
*
* @return string
*/
function size_of($name)
function size_of($name='')
{
global $lang;

Expand Down
2 changes: 1 addition & 1 deletion inc/cachehandlers/memcached.php
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ function disconnect()
*
* @return string
*/
function size_of($name)
function size_of($name='')
{
global $lang;

Expand Down
2 changes: 1 addition & 1 deletion inc/cachehandlers/xcache.php
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ function disconnect()
*
* @return string
*/
function size_of($name)
function size_of($name='')
{
global $lang;

Expand Down
2 changes: 1 addition & 1 deletion inc/class_parser.php
Original file line number Diff line number Diff line change
Expand Up @@ -658,7 +658,7 @@ function fix_javascript($message)
{
$js_array = array(
"#(&\#(0*)106;?|&\#(0*)74;?|&\#x(0*)4a;?|&\#x(0*)6a;?|j)((&\#(0*)97;?|&\#(0*)65;?|a)(&\#(0*)118;?|&\#(0*)86;?|v)(&\#(0*)97;?|&\#(0*)65;?|a)(\s)?(&\#(0*)115;?|&\#(0*)83;?|s)(&\#(0*)99;?|&\#(0*)67;?|c)(&\#(0*)114;?|&\#(0*)82;?|r)(&\#(0*)105;?|&\#(0*)73;?|i)(&\#112;?|&\#(0*)80;?|p)(&\#(0*)116;?|&\#(0*)84;?|t)(&\#(0*)58;?|\:))#i",
"#(on)([a-z]+\s?=)#i",
"#([\s\"']on)([a-z]+\s*=)#i",
);

// Add invisible white space
Expand Down
2 changes: 1 addition & 1 deletion install/resources/upgrade35.php
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ function upgrade35_dbchanges()
}

// Remove "Are You a Human" captcha
$db->update_query('settings', array('value' => 1), "name='captchaimage' AND value=3");
$db->update_query('settings', array('value' => '1'), "name='captchaimage' AND value='3'");
$db->delete_query('settings', "name IN ('ayahpublisherkey', 'ayahscoringkey')");
$db->delete_query('templates', "title IN ('member_register_regimage_ayah', 'post_captcha_ayah')");

Expand Down
6 changes: 4 additions & 2 deletions search.php
Original file line number Diff line number Diff line change
Expand Up @@ -247,7 +247,7 @@
// Normal moderators
$unapprove_forums = array();
$deleted_forums = array();
$unapproved_where = 't.visible = 1';
$unapproved_where = '(t.visible = 1';
while($moderator = $db->fetch_array($query))
{
if($moderator['canviewunapprove'] == 1)
Expand All @@ -269,6 +269,7 @@
{
$unapproved_where .= " OR (t.visible = -1 AND t.fid IN(".implode(',', $deleted_forums)."))";
}
$unapproved_where .= ')';
}
else
{
Expand Down Expand Up @@ -722,7 +723,7 @@
// Normal moderators
$unapprove_forums = array();
$deleted_forums = array();
$unapproved_where = 'visible = 1';
$unapproved_where = '(visible = 1';

while($moderator = $db->fetch_array($query))
{
Expand All @@ -745,6 +746,7 @@
{
$unapproved_where .= " OR (visible = -1 AND fid IN(".implode(',', $deleted_forums)."))";
}
$unapproved_where .= ')';
}
else
{
Expand Down

0 comments on commit c7a8925

Please sign in to comment.