This commit is contained in:
Deven Bansod 2015-11-26 20:02:57 +05:30
commit 07dce3d51b
7 changed files with 36 additions and 36 deletions

View File

@ -451,12 +451,12 @@ class ServerDatabasesController extends Controller
* Builds the HTML for one database to display in the list
* of databases from server_databases.php
*
* @param array $current current database
* @param string $url_query url query
* @param array $column_order column order
* @param array $replication_types replication types
* @param array $replication_info replication info
* @param string $tr_class HTMl class for the row
* @param array $current current database
* @param string $url_query url query
* @param array $column_order column order
* @param array $replication_types replication types
* @param array $replication_info replication info
* @param string $tr_class HTMl class for the row
*
* @return array $column_order, $out
*/
@ -484,8 +484,8 @@ class ServerDatabasesController extends Controller
if (/*overload*/mb_strlen($key) > 0
|| (isset($replication_info[$type]['Do_DB'][0])
&& $replication_info[$type]['Do_DB'][0] == ""
&& count($replication_info[$type]['Do_DB']) == 1)
&& $replication_info[$type]['Do_DB'][0] == ""
&& count($replication_info[$type]['Do_DB']) == 1)
) {
// if ($key != null) did not work for index "0"
$out = Util::getIcon(

View File

@ -2047,8 +2047,8 @@ function PMA_updatePassword($err_url, $username, $hostname)
if (empty($message)) {
$hashing_function = 'PASSWORD';
$serverType = Util::getServerType();
$authentication_plugin =
(isset($_REQUEST['authentication_plugin'])
$authentication_plugin
= (isset($_REQUEST['authentication_plugin'])
? $_REQUEST['authentication_plugin']
: PMA_getCurrentAuthenticationPlugin(
'change',

View File

@ -31,7 +31,7 @@ class DatabaseStructureControllerTest extends PHPUnit_Framework_TestCase
/**
* @var \PMA\Test\Stubs\Response
*/
private $response;
private $_response;
/**
* Prepares environment for the test.
@ -84,8 +84,8 @@ class DatabaseStructureControllerTest extends PHPUnit_Framework_TestCase
$container->set('db', 'db');
$container->set('table', 'table');
$container->set('dbi', $GLOBALS['dbi']);
$this->response = new \PMA\Test\Stubs\Response();
$container->set('PMA\libraries\Response', $this->response);
$this->_response = new \PMA\Test\Stubs\Response();
$container->set('PMA\libraries\Response', $this->_response);
$container->alias('response', 'PMA\libraries\Response');
}
@ -368,7 +368,7 @@ class DatabaseStructureControllerTest extends PHPUnit_Framework_TestCase
);
$method->invokeArgs($ctrl, array($fav_instance, $user, $favorite_table));
$json = $this->response->getJSONResult();
$json = $this->_response->getJSONResult();
$this->assertEquals(json_encode($favorite_table), $json['favorite_tables']);
$this->assertArrayHasKey('list', $json);
@ -395,7 +395,7 @@ class DatabaseStructureControllerTest extends PHPUnit_Framework_TestCase
);
$ctrl->handleRealRowCountRequestAction();
$json = $this->response->getJSONResult();
$json = $this->_response->getJSONResult();
$this->assertEquals(
6,
$json['real_row_count']
@ -409,7 +409,7 @@ class DatabaseStructureControllerTest extends PHPUnit_Framework_TestCase
)
);
$ctrl->handleRealRowCountRequestAction();
$json = $this->response->getJSONResult();
$json = $this->_response->getJSONResult();
$expected_result = array(
array(

View File

@ -28,7 +28,7 @@ class TableRelationControllerTest extends PHPUnit_Framework_TestCase
/**
* @var \PMA\Test\Stubs\Response
*/
private $response;
private $_response;
/**
* Configures environment
@ -60,8 +60,8 @@ class TableRelationControllerTest extends PHPUnit_Framework_TestCase
$container->set('db', 'db');
$container->set('table', 'table');
$container->set('dbi', $GLOBALS['dbi']);
$this->response = new \PMA\Test\Stubs\Response();
$container->set('PMA\libraries\Response', $this->response);
$this->_response = new \PMA\Test\Stubs\Response();
$container->set('PMA\libraries\Response', $this->_response);
$container->alias('response', 'PMA\libraries\Response');
}
@ -104,7 +104,7 @@ class TableRelationControllerTest extends PHPUnit_Framework_TestCase
$ctrl = $container->get('TableRelationController');
$ctrl->getDropdownValueForTableAction();
$json = $this->response->getJSONResult();
$json = $this->_response->getJSONResult();
$this->assertEquals(
$viewColumns,
$json['columns']
@ -147,7 +147,7 @@ class TableRelationControllerTest extends PHPUnit_Framework_TestCase
$ctrl = $container->get('TableRelationController');
$ctrl->getDropdownValueForTableAction();
$json = $this->response->getJSONResult();
$json = $this->_response->getJSONResult();
$this->assertEquals(
$indexedColumns,
$json['columns']
@ -193,7 +193,7 @@ class TableRelationControllerTest extends PHPUnit_Framework_TestCase
$_REQUEST['foreign'] = 'true';
$ctrl->getDropdownValueForDbAction();
$json = $this->response->getJSONResult();
$json = $this->_response->getJSONResult();
$this->assertEquals(
array('table'),
$json['tables']
@ -239,7 +239,7 @@ class TableRelationControllerTest extends PHPUnit_Framework_TestCase
$_REQUEST['foreign'] = 'false';
$ctrl->getDropdownValueForDbAction();
$json = $this->response->getJSONResult();
$json = $this->_response->getJSONResult();
$this->assertEquals(
array('table'),
$json['tables']

View File

@ -26,7 +26,7 @@ class TableSearchControllerTest extends PHPUnit_Framework_TestCase
/**
* @var PMA\Test\Stubs\Response
*/
private $response;
private $_response;
/**
* Setup function for test cases
@ -96,13 +96,13 @@ class TableSearchControllerTest extends PHPUnit_Framework_TestCase
$GLOBALS['dbi'] = $dbi;
$this->response = new PMA\Test\Stubs\Response();
$this->_response = new PMA\Test\Stubs\Response();
$container = Container::getDefaultContainer();
$container->set('db', 'PMA');
$container->set('table', 'PMA_BookMark');
$container->set('dbi', $GLOBALS['dbi']);
$container->set('response', $this->response);
$container->set('response', $this->_response);
$container->set('searchType', 'replace');
}
@ -380,7 +380,7 @@ class TableSearchControllerTest extends PHPUnit_Framework_TestCase
);
$ctrl->getDataRowAction();
$json = $this->response->getJSONResult();
$json = $this->_response->getJSONResult();
$this->assertEquals(
$expected,
$json['row_info']

View File

@ -29,7 +29,7 @@ class TableStructureControllerTest extends PHPUnit_Framework_TestCase
/**
* @var \PMA\Test\Stubs\Response
*/
private $response;
private $_response;
/**
* Prepares environment for the test.
@ -77,8 +77,8 @@ class TableStructureControllerTest extends PHPUnit_Framework_TestCase
$container->set('db', 'db');
$container->set('table', 'table');
$container->set('dbi', $GLOBALS['dbi']);
$this->response = new \PMA\Test\Stubs\Response();
$container->set('PMA\libraries\Response', $this->response);
$this->_response = new \PMA\Test\Stubs\Response();
$container->set('PMA\libraries\Response', $this->_response);
$container->alias('response', 'PMA\libraries\Response');
}

View File

@ -212,12 +212,12 @@ function PMA_changePassHashingFunction()
/**
* Generate the error url and submit the query
*
* @param string $username Username
* @param string $hostname Hostname
* @param string $password Password
* @param string $sql_query SQL query
* @param string $hashing_function Hashing function
* @param string $orig_auth_plugin Original Authentication Plugin
* @param string $username Username
* @param string $hostname Hostname
* @param string $password Password
* @param string $sql_query SQL query
* @param string $hashing_function Hashing function
* @param string $orig_auth_plugin Original Authentication Plugin
*
* @return void
*/