Edit File by line

Deprecated: str_replace(): Passing null to parameter #2 ($replace) of type array|string is deprecated in /home/sportsfever/public_html/filemanger/function.php on line 93
/home/sportsfe.../httpdocs/wp-conte.../plugins/flow-flo.../includes/db/migratio...
File: FFMigration_2_8.php
<?php namespace flow\db\migrations;
[0] Fix | Delete
use Exception;
[1] Fix | Delete
use la\core\db\LADDLUtils;
[2] Fix | Delete
use la\core\db\migrations\ILADBMigration;
[3] Fix | Delete
[4] Fix | Delete
if ( ! defined( 'WPINC' ) ) die;
[5] Fix | Delete
/**
[6] Fix | Delete
* FlowFlow.
[7] Fix | Delete
*
[8] Fix | Delete
* @package FlowFlow
[9] Fix | Delete
* @author Looks Awesome <email@looks-awesome.com>
[10] Fix | Delete
*
[11] Fix | Delete
* @link http://looks-awesome.com
[12] Fix | Delete
* @copyright Looks Awesome
[13] Fix | Delete
*/
[14] Fix | Delete
class FFMigration_2_8 implements ILADBMigration{
[15] Fix | Delete
[16] Fix | Delete
public function version() {
[17] Fix | Delete
return '2.8';
[18] Fix | Delete
}
[19] Fix | Delete
[20] Fix | Delete
public function execute($conn, $manager) {
[21] Fix | Delete
LADDLUtils::addColumnIfNotExist($conn, $manager->posts_table_name, 'smart_order', 'INT NULL');
[22] Fix | Delete
[23] Fix | Delete
if (false !== ($feeds = $conn->getCol('SELECT DISTINCT `feed_id` FROM ?n', $manager->posts_table_name))){
[24] Fix | Delete
foreach ( $feeds as $feed ) {
[25] Fix | Delete
if (false === ($posts = $conn->getCol('SELECT `post_id` FROM ?n WHERE `feed_id` = ?s ORDER BY post_timestamp DESC', $manager->posts_table_name, $feed))){
[26] Fix | Delete
throw new Exception($conn->getError());
[27] Fix | Delete
}
[28] Fix | Delete
$index = 0;
[29] Fix | Delete
foreach ( $posts as $post ) {
[30] Fix | Delete
if (false === $conn->query('UPDATE ?n SET `smart_order` = ?i WHERE `feed_id` = ?s AND `post_id` = ?s',
[31] Fix | Delete
$manager->posts_table_name, $index, $feed, $post)){
[32] Fix | Delete
throw new Exception($conn->getError());
[33] Fix | Delete
}
[34] Fix | Delete
$index++;
[35] Fix | Delete
}
[36] Fix | Delete
}
[37] Fix | Delete
}
[38] Fix | Delete
}
[39] Fix | Delete
}
[40] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function