Add a trailing comma in multi-line arrays

Signed-off-by: Maurício Meneghini Fauth <mauricio@fauth.dev>
This commit is contained in:
Maurício Meneghini Fauth 2019-06-14 14:09:26 -03:00
parent 34541f565c
commit e1f9ae00cd
116 changed files with 369 additions and 369 deletions

View File

@ -101,7 +101,7 @@ $replaces = [
=> '\\1<b>\\2</b>',
// Links target and rel
'/a href="/' => 'a target="_blank" rel="noopener noreferrer" href="'
'/a href="/' => 'a target="_blank" rel="noopener noreferrer" href="',
];

View File

@ -77,7 +77,7 @@ if (isset($_POST['console_bookmark_add'])) {
'bkm_database' => $_POST['db'],
'bkm_user' => $cfgBookmark['user'],
'bkm_sql_query' => $_POST['bookmark_query'],
'bkm_label' => $_POST['label']
'bkm_label' => $_POST['label'],
];
$isShared = ($_POST['shared'] == 'true' ? true : false);
$bookmark = Bookmark::createBookmark(

View File

@ -713,12 +713,12 @@ class Config
$author = [
'name' => '',
'email' => '',
'date' => ''
'date' => '',
];
$committer = [
'name' => '',
'email' => '',
'date' => ''
'date' => '',
];
do {
@ -731,7 +731,7 @@ class Config
$user2 = [
'name' => trim($user[1]),
'email' => trim($user[2]),
'date' => date('Y-m-d H:i:s', (int) $user[3])
'date' => date('Y-m-d H:i:s', (int) $user[3]),
];
if (isset($user[4])) {
$user2['date'] .= $user[4];
@ -744,12 +744,12 @@ class Config
$author = [
'name' => $commit_json->author->name,
'email' => $commit_json->author->email,
'date' => $commit_json->author->date
'date' => $commit_json->author->date,
];
$committer = [
'name' => $commit_json->committer->name,
'email' => $commit_json->committer->email,
'date' => $commit_json->committer->date
'date' => $commit_json->committer->date,
];
$message = trim($commit_json->message);
} else {

View File

@ -103,7 +103,7 @@ class FormDisplay
'error_nan_nneg' => __('Not a non-negative number!'),
'error_incorrect_port' => __('Not a valid port number!'),
'error_invalid_value' => __('Incorrect value!'),
'error_value_lte' => __('Value must be less than or equal to %s!')
'error_value_lte' => __('Value must be less than or equal to %s!'),
];
$this->_configFile = $cf;
// initialize validators
@ -406,7 +406,7 @@ class FormDisplay
'doc' => $this->getDocLink($systemPath),
'show_restore_default' => $showRestoreDefault,
'userprefs_allow' => $userPrefsAllow,
'userprefs_comment' => Descriptions::get($systemPath, 'cmt')
'userprefs_comment' => Descriptions::get($systemPath, 'cmt'),
];
if (isset($form->default[$systemPath])) {
$opts['setvalue'] = (string) $form->default[$systemPath];

View File

@ -40,7 +40,7 @@ class FeaturesForm extends \PhpMyAdmin\Config\Forms\User\FeaturesForm
'ZipDump',
'GZipDump',
'BZipDump',
'CompressOnFly'
'CompressOnFly',
];
$result['Security'] = [
'blowfish_secret',

View File

@ -95,7 +95,7 @@ class ServersForm extends BaseForm
'central_columns' => 'pma__central_columns',
'designer_settings' => 'pma__designer_settings',
'export_templates' => 'pma__export_templates',
'MaxTableUiprefs' => 100
'MaxTableUiprefs' => 100,
],
],
],

View File

@ -42,7 +42,7 @@ class ExportForm extends BaseForm
':group:end',
'Export/file_template_table',
'Export/file_template_database',
'Export/file_template_server'
'Export/file_template_server',
],
'Sql' => [
'Export/sql_include_comments' => ':group',
@ -79,10 +79,10 @@ class ExportForm extends BaseForm
'Export/sql_insert_syntax',
'Export/sql_max_query_size',
'Export/sql_hex_for_binary',
'Export/sql_utc_time'
'Export/sql_utc_time',
],
'CodeGen' => [
'Export/codegen_format'
'Export/codegen_format',
],
'Csv' => [
':group:' . __('CSV'),

View File

@ -79,7 +79,7 @@ class FeaturesForm extends BaseForm
// skip Developer form if no setting is available
if ($GLOBALS['cfg']['UserprefsDeveloperTab']) {
$result['Developer'] = [
'DBG/sql'
'DBG/sql',
];
}
return $result;

View File

@ -83,7 +83,7 @@ class MainForm extends BaseForm
'DefaultTabTable',
],
'DisplayRelationalSchema' => [
'PDFDefaultPageSize'
'PDFDefaultPageSize',
],
];
}

View File

@ -72,7 +72,7 @@ class SpecialSchemaLinks
'column_name' => 'host',
],
],
'default_page' => './server_privileges.php'
'default_page' => './server_privileges.php',
],
'table_name' => [
'link_param' => 'table',
@ -96,7 +96,7 @@ class SpecialSchemaLinks
'column_name' => 'Table_name',
],
],
'default_page' => './tbl_structure.php?change_column=1'
'default_page' => './tbl_structure.php?change_column=1',
],
],
'db' => [
@ -108,7 +108,7 @@ class SpecialSchemaLinks
'column_name' => 'host',
],
],
'default_page' => './server_privileges.php'
'default_page' => './server_privileges.php',
],
],
'event' => [
@ -120,7 +120,7 @@ class SpecialSchemaLinks
'column_name' => 'db',
],
],
'default_page' => './db_events.php?edit_item=1'
'default_page' => './db_events.php?edit_item=1',
],
],
@ -147,7 +147,7 @@ class SpecialSchemaLinks
'column_name' => 'table_name',
],
],
'default_page' => './tbl_structure.php'
'default_page' => './tbl_structure.php',
],
],
'innodb_table_stats' => [
@ -175,7 +175,7 @@ class SpecialSchemaLinks
'column_name' => 'type',
],
],
'default_page' => './db_routines.php?edit_item=1'
'default_page' => './db_routines.php?edit_item=1',
],
'specific_name' => [
'link_param' => 'item_name',
@ -189,7 +189,7 @@ class SpecialSchemaLinks
'column_name' => 'type',
],
],
'default_page' => './db_routines.php?edit_item=1'
'default_page' => './db_routines.php?edit_item=1',
],
],
'proc_priv' => [
@ -201,7 +201,7 @@ class SpecialSchemaLinks
'column_name' => 'Host',
],
],
'default_page' => './server_privileges.php'
'default_page' => './server_privileges.php',
],
'routine_name' => [
'link_param' => 'item_name',
@ -215,7 +215,7 @@ class SpecialSchemaLinks
'column_name' => 'Routine_type',
],
],
'default_page' => './db_routines.php?edit_item=1'
'default_page' => './db_routines.php?edit_item=1',
],
],
'proxies_priv' => [
@ -227,7 +227,7 @@ class SpecialSchemaLinks
'column_name' => 'Host',
],
],
'default_page' => './server_privileges.php'
'default_page' => './server_privileges.php',
],
],
'tables_priv' => [
@ -239,7 +239,7 @@ class SpecialSchemaLinks
'column_name' => 'Host',
],
],
'default_page' => './server_privileges.php'
'default_page' => './server_privileges.php',
],
'table_name' => [
'link_param' => 'table',
@ -261,9 +261,9 @@ class SpecialSchemaLinks
'column_name' => 'host',
],
],
'default_page' => './server_privileges.php'
'default_page' => './server_privileges.php',
],
]
],
],
'information_schema' => [
'columns' => [
@ -289,7 +289,7 @@ class SpecialSchemaLinks
'column_name' => 'table_name',
],
],
'default_page' => './tbl_structure.php?change_column=1'
'default_page' => './tbl_structure.php?change_column=1',
],
],
'key_column_usage' => [
@ -315,7 +315,7 @@ class SpecialSchemaLinks
'column_name' => 'table_name',
],
],
'default_page' => './tbl_structure.php?change_column=1'
'default_page' => './tbl_structure.php?change_column=1',
],
'referenced_table_name' => [
'link_param' => 'table',
@ -339,7 +339,7 @@ class SpecialSchemaLinks
'column_name' => 'referenced_table_name',
],
],
'default_page' => './tbl_structure.php?change_column=1'
'default_page' => './tbl_structure.php?change_column=1',
],
],
'partitions' => [
@ -363,7 +363,7 @@ class SpecialSchemaLinks
'column_name' => 'host',
],
],
'default_page' => './server_privileges.php'
'default_page' => './server_privileges.php',
],
],
'referential_constraints' => [
@ -401,7 +401,7 @@ class SpecialSchemaLinks
'column_name' => 'routine_type',
],
],
'default_page' => './db_routines.php'
'default_page' => './db_routines.php',
],
],
'schemata' => [
@ -433,7 +433,7 @@ class SpecialSchemaLinks
'column_name' => 'table_name',
],
],
'default_page' => './tbl_structure.php?change_column=1'
'default_page' => './tbl_structure.php?change_column=1',
],
],
'tables' => [

View File

@ -251,7 +251,7 @@ class Validator
'Server' => '',
'Servers/1/user' => '',
'Servers/1/SignonSession' => '',
'Servers/1/SignonURL' => ''
'Servers/1/SignonURL' => '',
];
$error = false;
if (empty($values['Servers/1/auth_type'])) {

View File

@ -641,7 +641,7 @@ class StructureController extends AbstractController
'hidden_fields' => $hidden_fields,
'disable_multi_table' => $GLOBALS['cfg']['DisableMultiTableMaintenance'],
'central_columns_work' => $GLOBALS['cfgRelation']['centralcolumnswork'],
]
],
]);
return $html;
@ -809,7 +809,7 @@ class StructureController extends AbstractController
$json = [
'favoriteTables' => json_encode($favoriteTables),
'list' => $favoriteInstance->getHtmlList()
'list' => $favoriteInstance->getHtmlList(),
];
$serverId = $GLOBALS['server'];
// Set flag when localStorage and pmadb(if present) are in sync.

View File

@ -181,7 +181,7 @@ class VariablesController extends AbstractController
// alert if more than 95% of thread cache is in use
'Threads_cached' => isset($this->data->variables['thread_cache_size'])
? 0.95 * $this->data->variables['thread_cache_size'] : 0
? 0.95 * $this->data->variables['thread_cache_size'] : 0,
// higher is better
// variable => min value
@ -633,7 +633,7 @@ class VariablesController extends AbstractController
),
'Threads_running' => __(
'The number of threads that are not sleeping.'
)
),
];
}
}

View File

@ -194,7 +194,7 @@ class HomeController extends AbstractController
$eolOptions = [
'values' => [
'unix' => 'UNIX / Linux (\n)',
'win' => 'Windows (\r\n)'
'win' => 'Windows (\r\n)',
],
'values_escaped' => true,
];

View File

@ -206,7 +206,7 @@ class GisVisualizationController extends AbstractController
[
'saveToFile' => true,
'session_max_rows' => $rows,
'pos' => $pos
'pos' => $pos,
]
)
);

View File

@ -366,7 +366,7 @@ class SearchController extends AbstractController
$row[$_POST['criteriaColumnNames'][0]],
$_POST['criteriaColumnNames'][1] =>
$row[$_POST['criteriaColumnNames'][1]],
'where_clause' => $uniqueCondition[0]
'where_clause' => $uniqueCondition[0],
];
$tmpData[$dataLabel] = $dataLabel ? $row[$dataLabel] : '';
$data[] = $tmpData;
@ -974,7 +974,7 @@ class SearchController extends AbstractController
'type' => $type,
'collation' => $collation,
'func' => $func,
'value' => $value
'value' => $value,
];
}

View File

@ -1284,7 +1284,7 @@ class Qbe
return [
'unique' => $unique_columns,
'index' => $index_columns
'index' => $index_columns,
];
}

View File

@ -2280,7 +2280,7 @@ class DatabaseInterface
Url::getCommon(
[
'engine' => 'InnoDB',
'page' => 'Status'
'page' => 'Status',
]
) . '">' . __('Details…') . '</a>)';
}

View File

@ -300,7 +300,7 @@ class Results
],
'views' => [
'view_definition' => $sql_highlighting_data,
]
],
],
'mysql' => [
'event' => [
@ -315,18 +315,18 @@ class Results
],
'help_topic' => [
'example' => $sql_highlighting_data,
'url' => $link_data
'url' => $link_data,
],
'proc' => [
'param_list' => $blob_sql_highlighting_data,
'returns' => $blob_sql_highlighting_data,
'body' => $blob_sql_highlighting_data,
'body_utf8' => $blob_sql_highlighting_data
'body_utf8' => $blob_sql_highlighting_data,
],
'slow_log' => [
'sql_text' => $sql_highlighting_data,
]
]
],
],
];
$cfgRelation = $this->relation->getRelationsParam();
@ -346,7 +346,7 @@ class Results
if (! empty($cfgRelation['tracking'])) {
$relDb[$cfgRelation['tracking']] = [
'schema_sql' => $sql_highlighting_data,
'data_sql' => $sql_highlighting_data
'data_sql' => $sql_highlighting_data,
];
}
if (! empty($cfgRelation['favorite'])) {

View File

@ -102,7 +102,7 @@ class ErrorReport
"locale" => $_COOKIE['pma_lang'],
"configuration_storage" =>
$relParams['db'] === null ? "disabled" : "enabled",
"php_version" => PHP_VERSION
"php_version" => PHP_VERSION,
];
if ($exceptionType == 'js') {
@ -156,7 +156,7 @@ class ErrorReport
"type" => $errorObj->getType(),
"msg" => $errorObj->getOnlyMessage(),
"stackTrace" => $errorObj->getBacktrace(5),
"stackhash" => $errorObj->getHash()
"stackhash" => $errorObj->getHash(),
];
}
}

View File

@ -201,7 +201,7 @@ abstract class GisGeometry
return [
'srid' => $srid,
'wkt' => $wkt
'wkt' => $wkt,
];
}

View File

@ -261,7 +261,7 @@ class Header
'is_https' => $GLOBALS['PMA_Config']->isHttps(),
'rootPath' => $GLOBALS['PMA_Config']->getRootPath(),
'arg_separator' => Url::getArgSeparator(),
'PMA_VERSION' => PMA_VERSION
'PMA_VERSION' => PMA_VERSION,
];
if (isset($GLOBALS['cfg']['Server'])
&& isset($GLOBALS['cfg']['Server']['auth_type'])

View File

@ -2308,7 +2308,7 @@ class InsertEdit
$insert_command . 'INTO '
. Util::backquote($GLOBALS['table'])
. ' (' . implode(', ', $query_fields) . ') VALUES ('
. implode('), (', $value_sets) . ')'
. implode('), (', $value_sets) . ')',
];
return $query;
}

View File

@ -42,7 +42,7 @@ class InternalRelations
'foreign_db' => 'information_schema',
'foreign_table' => 'COLLATIONS',
'foreign_field' => 'COLLATION_NAME',
]
],
],
'COLUMNS' => [
'TABLE_SCHEMA' => [
@ -59,7 +59,7 @@ class InternalRelations
'foreign_db' => 'information_schema',
'foreign_table' => 'COLLATIONS',
'foreign_field' => 'COLLATION_NAME',
]
],
],
'COLUMN_PRIVILEGES' => [
'TABLE_SCHEMA' => [
@ -88,7 +88,7 @@ class InternalRelations
'foreign_db' => 'information_schema',
'foreign_table' => 'COLLATIONS',
'foreign_field' => 'COLLATION_NAME',
]
],
],
'FILES' => [
'TABLESPACE_NAME' => [
@ -110,7 +110,7 @@ class InternalRelations
'foreign_db' => 'information_schema',
'foreign_table' => 'ENGINES',
'foreign_field' => 'ENGINE',
]
],
],
'KEY_COLUMN_USAGE' => [
'CONSTRAINT_SCHEMA' => [
@ -144,7 +144,7 @@ class InternalRelations
'foreign_db' => 'information_schema',
'foreign_table' => 'COLLATIONS',
'foreign_field' => 'COLLATION_NAME',
]
],
],
'PARTITIONS' => [
'TABLE_SCHEMA' => [
@ -207,7 +207,7 @@ class InternalRelations
'foreign_db' => 'information_schema',
'foreign_table' => 'COLLATIONS',
'foreign_field' => 'COLLATION_NAME',
]
],
],
'SCHEMATA' => [
'DEFAULT_CHARACTER_SET_NAME' => [
@ -219,7 +219,7 @@ class InternalRelations
'foreign_db' => 'information_schema',
'foreign_table' => 'COLLATIONS',
'foreign_field' => 'COLLATION_NAME',
]
],
],
'SCHEMA_PRIVILEGES' => [
'TABLE_SCHEMA' => [
@ -274,7 +274,7 @@ class InternalRelations
'foreign_db' => 'information_schema',
'foreign_table' => 'SCHEMATA',
'foreign_field' => 'SCHEMA_NAME',
]
],
],
'TABLE_PRIVILEGES' => [
'TABLE_SCHEMA' => [
@ -308,7 +308,7 @@ class InternalRelations
'foreign_db' => 'information_schema',
'foreign_table' => 'COLLATIONS',
'foreign_field' => 'COLLATION_NAME',
]
],
],
'VIEWS' => [
'TABLE_SCHEMA' => [
@ -326,7 +326,7 @@ class InternalRelations
'foreign_table' => 'COLLATIONS',
'foreign_field' => 'COLLATION_NAME',
],
]
],
];
/**

View File

@ -134,7 +134,7 @@ class ListDatabase extends ListAbstract
&& strlen($GLOBALS['cfg']['Server']['only_db']) > 0
) {
$GLOBALS['cfg']['Server']['only_db'] = [
$GLOBALS['cfg']['Server']['only_db']
$GLOBALS['cfg']['Server']['only_db'],
];
}

View File

@ -46,7 +46,7 @@ abstract class NodeDatabaseChild extends Node
'hideNavItem' => true,
'itemType' => $this->getItemType(),
'itemName' => $item,
'dbName' => $db
'dbName' => $db,
];
$ret = '<span class="navItemControls">'

View File

@ -153,7 +153,7 @@ class Normalization
'move_columns' => [],
'cfg_relation' => $cfgRelation,
'available_mime' => $availableMime,
'mime_map' => $mimeMap
'mime_map' => $mimeMap,
];
}
@ -277,7 +277,7 @@ class Normalization
'headText' => $headText,
'subText' => $subText,
'hasPrimaryKey' => $hasPrimaryKey,
'extra' => $extra
'extra' => $extra,
];
}
@ -313,7 +313,7 @@ class Normalization
'legendText' => $legendText,
'headText' => $headText,
'subText' => $subText,
'extra' => $extra
'extra' => $extra,
];
}
@ -562,7 +562,7 @@ class Normalization
'legendText' => __('End of step'),
'headText' => $headText,
'queryError' => $error,
'extra' => $message
'extra' => $message,
];
}
@ -628,7 +628,7 @@ class Normalization
return [
'html' => $html,
'newTables' => $newTables,
'success' => true
'success' => true,
];
}
@ -718,7 +718,7 @@ class Normalization
'legendText' => __('End of step'),
'headText' => $headText,
'queryError' => $error,
'extra' => $message
'extra' => $message,
];
}
@ -791,7 +791,7 @@ class Normalization
}
return [
'queryError' => $error,
'message' => $message
'message' => $message,
];
}
@ -871,7 +871,7 @@ class Normalization
'legendText' => $legendText,
'headText' => $headText,
'subText' => $subText,
'extra' => $extra
'extra' => $extra,
];
}
@ -896,7 +896,7 @@ class Normalization
$choices = [
'1nf' => __('First step of normalization (1NF)'),
'2nf' => __('Second step of normalization (1NF+2NF)'),
'3nf' => __('Third step of normalization (1NF+2NF+3NF)')
'3nf' => __('Third step of normalization (1NF+2NF+3NF)'),
];
$htmlOutput .= Util::getRadioFields(

View File

@ -1261,25 +1261,25 @@ class Operations
'ARIA' => [
'FIXED' => 'FIXED',
'DYNAMIC' => 'DYNAMIC',
'PAGE' => 'PAGE'
'PAGE' => 'PAGE',
],
'MARIA' => [
'FIXED' => 'FIXED',
'DYNAMIC' => 'DYNAMIC',
'PAGE' => 'PAGE'
'PAGE' => 'PAGE',
],
'MYISAM' => [
'FIXED' => 'FIXED',
'DYNAMIC' => 'DYNAMIC'
'DYNAMIC' => 'DYNAMIC',
],
'PBXT' => [
'FIXED' => 'FIXED',
'DYNAMIC' => 'DYNAMIC'
'DYNAMIC' => 'DYNAMIC',
],
'INNODB' => [
'COMPACT' => 'COMPACT',
'REDUNDANT' => 'REDUNDANT',
]
],
];
/** @var Innodb $innodbEnginePlugin */

View File

@ -228,7 +228,7 @@ class ExportJson extends ExportPlugin
'type' => 'table',
'name' => $table_alias,
'database' => $db_alias,
'data' => "@@DATA@@"
'data' => "@@DATA@@",
]
);
list($header, $footer) = explode('"@@DATA@@"', $buffer);

View File

@ -142,7 +142,7 @@ class ExportPdf extends ExportPlugin
$attr = [
'titleFontSize' => 18,
'titleText' => $pdf_report_title
'titleText' => $pdf_report_title,
];
$pdf->setAttributes($attr);
$pdf->setTopMargin(30);

View File

@ -300,7 +300,7 @@ class Sanitize
'\'' => '\\\'',
'"' => '\"',
"\n" => '\n',
"\r" => '\r'
"\r" => '\r',
]
)
);

View File

@ -293,7 +293,7 @@ class SavedSearches
if (null === $this->getId()) {
$wheres = [
"search_name = '" . $GLOBALS['dbi']->escapeString($this->getSearchName())
. "'"
. "'",
];
$existingSearches = $this->getList($wheres);

View File

@ -271,7 +271,7 @@ class Privileges
if ($enableHTML) {
$privs = ['<dfn title="'
. __('Includes all privileges except GRANT.')
. '">ALL PRIVILEGES</dfn>'
. '">ALL PRIVILEGES</dfn>',
];
} else {
$privs = ['ALL PRIVILEGES'];
@ -610,7 +610,7 @@ class Privileges
return $this->template->render('server/privileges/choose_user_group', [
'all_user_groups' => $allUserGroups,
'user_group' => $userGroup,
'params' => ['username' => $username]
'params' => ['username' => $username],
]);
}
@ -4206,7 +4206,7 @@ class Privileges
{
if (isset($_POST['change_copy'])) {
$selected_usr = [
$_POST['old_username'] . '&amp;#27;' . $_POST['old_hostname']
$_POST['old_username'] . '&amp;#27;' . $_POST['old_hostname'],
];
} else {
$selected_usr = $_POST['selected_usr'];

View File

@ -131,7 +131,7 @@ class Data
'tc' => __('Transaction coordinator'),
'files' => __('Files'),
'ssl' => 'SSL',
'other' => __('Other')
'other' => __('Other'),
];
}

View File

@ -276,7 +276,7 @@ class Monitor
$return = [
'rows' => [],
'sum' => []
'sum' => [],
];
while ($row = $this->dbi->fetchAssoc($result)) {
@ -356,7 +356,7 @@ class Monitor
$return = [
'rows' => [],
'sum' => []
'sum' => [],
];
$insertTables = [];
$insertTablesFirst = -1;

View File

@ -128,7 +128,7 @@ class UserGroups
. Url::getCommon(
[
'editUserGroup' => 1,
'userGroup' => $groupName
'userGroup' => $groupName,
],
''
)
@ -140,7 +140,7 @@ class UserGroups
. Url::getCommon(
[
'deleteUserGroup' => 1,
'userGroup' => $groupName
'userGroup' => $groupName,
],
''
)

View File

@ -209,7 +209,7 @@ class Tracking
'type' => $type,
'default_statements' => $GLOBALS['cfg']['Server']['tracking_default_statements'],
'pmaThemeImage' => $pmaThemeImage,
'text_dir' => $textDir
'text_dir' => $textDir,
]);
}

View File

@ -107,7 +107,7 @@ class Transformations
$sub_dirs = [
'Input/' => 'input_',
'Output/' => '',
'' => ''
'' => '',
];
foreach ($sub_dirs as $sd => $prefix) {

View File

@ -58,7 +58,7 @@ class SanitizeExtension extends AbstractExtension
'get_js_value',
'PhpMyAdmin\Sanitize::getJsValue',
['is_safe' => ['html']]
)
),
];
}
}

View File

@ -862,7 +862,7 @@ class Types
'-9223372036854775808',
'9223372036854775807',
],
]
],
];
$relevantArray = $signed
? $min_max_data['signed']

View File

@ -94,7 +94,7 @@ class UserPassword
}
return [
'error' => $error,
'msg' => $message
'msg' => $message,
];
}

View File

@ -89,7 +89,7 @@ class UserPreferences
return [
'config_data' => $_SESSION['userconfig']['db'],
'mtime' => $_SESSION['userconfig']['ts'],
'type' => 'session'
'type' => 'session',
];
}
// load configuration from pmadb
@ -105,7 +105,7 @@ class UserPreferences
return [
'config_data' => $row ? json_decode($row['config_data'], true) : [],
'mtime' => $row ? $row['ts'] : time(),
'type' => 'db'
'type' => 'db',
];
}

View File

@ -1431,7 +1431,7 @@ class Util
5 => 'P',
6 => 'E',
7 => 'Z',
8 => 'Y'
8 => 'Y',
];
/* l10n: Decimal separator */
$decimal_sep = __('.');
@ -2721,7 +2721,7 @@ class Util
'toggle_on' => $options[1]['label'],
'toggle_off' => $options[0]['label'],
'callback' => $callback,
'state' => $state
'state' => $state,
]);
}
@ -2987,7 +2987,7 @@ class Util
'zerofill' => $zerofill,
'attribute' => $attribute,
'can_contain_collation' => $can_contain_collation,
'displayed_type' => $displayed_type
'displayed_type' => $displayed_type,
];
}
@ -3628,27 +3628,27 @@ class Util
// Unary functions common to all geometry types
$funcs['Dimension'] = [
'params' => 1,
'type' => 'int'
'type' => 'int',
];
$funcs['Envelope'] = [
'params' => 1,
'type' => 'Polygon'
'type' => 'Polygon',
];
$funcs['GeometryType'] = [
'params' => 1,
'type' => 'text'
'type' => 'text',
];
$funcs['SRID'] = [
'params' => 1,
'type' => 'int'
'type' => 'int',
];
$funcs['IsEmpty'] = [
'params' => 1,
'type' => 'int'
'type' => 'int',
];
$funcs['IsSimple'] = [
'params' => 1,
'type' => 'int'
'type' => 'int',
];
$geom_type = trim(mb_strtolower((string) $geom_type));
@ -3660,70 +3660,70 @@ class Util
if ($geom_type == 'point') {
$funcs['X'] = [
'params' => 1,
'type' => 'float'
'type' => 'float',
];
$funcs['Y'] = [
'params' => 1,
'type' => 'float'
'type' => 'float',
];
} elseif ($geom_type == 'linestring') {
$funcs['EndPoint'] = [
'params' => 1,
'type' => 'point'
'type' => 'point',
];
$funcs['GLength'] = [
'params' => 1,
'type' => 'float'
'type' => 'float',
];
$funcs['NumPoints'] = [
'params' => 1,
'type' => 'int'
'type' => 'int',
];
$funcs['StartPoint'] = [
'params' => 1,
'type' => 'point'
'type' => 'point',
];
$funcs['IsRing'] = [
'params' => 1,
'type' => 'int'
'type' => 'int',
];
} elseif ($geom_type == 'multilinestring') {
$funcs['GLength'] = [
'params' => 1,
'type' => 'float'
'type' => 'float',
];
$funcs['IsClosed'] = [
'params' => 1,
'type' => 'int'
'type' => 'int',
];
} elseif ($geom_type == 'polygon') {
$funcs['Area'] = [
'params' => 1,
'type' => 'float'
'type' => 'float',
];
$funcs['ExteriorRing'] = [
'params' => 1,
'type' => 'linestring'
'type' => 'linestring',
];
$funcs['NumInteriorRings'] = [
'params' => 1,
'type' => 'int'
'type' => 'int',
];
} elseif ($geom_type == 'multipolygon') {
$funcs['Area'] = [
'params' => 1,
'type' => 'float'
'type' => 'float',
];
$funcs['Centroid'] = [
'params' => 1,
'type' => 'point'
'type' => 'point',
];
// Not yet implemented in MySQL
//$funcs['PointOnSurface'] = array('params' => 1, 'type' => 'point');
} elseif ($geom_type == 'geometrycollection') {
$funcs['NumGeometries'] = [
'params' => 1,
'type' => 'int'
'type' => 'int',
];
}
@ -3737,70 +3737,70 @@ class Util
if ($GLOBALS['dbi']->getVersion() < 50601) {
$funcs['Crosses'] = [
'params' => 2,
'type' => 'int'
'type' => 'int',
];
$funcs['Contains'] = [
'params' => 2,
'type' => 'int'
'type' => 'int',
];
$funcs['Disjoint'] = [
'params' => 2,
'type' => 'int'
'type' => 'int',
];
$funcs['Equals'] = [
'params' => 2,
'type' => 'int'
'type' => 'int',
];
$funcs['Intersects'] = [
'params' => 2,
'type' => 'int'
'type' => 'int',
];
$funcs['Overlaps'] = [
'params' => 2,
'type' => 'int'
'type' => 'int',
];
$funcs['Touches'] = [
'params' => 2,
'type' => 'int'
'type' => 'int',
];
$funcs['Within'] = [
'params' => 2,
'type' => 'int'
'type' => 'int',
];
} else {
// If MySQl version is greater than or equal 5.6.1,
// use the ST_ prefix.
$funcs['ST_Crosses'] = [
'params' => 2,
'type' => 'int'
'type' => 'int',
];
$funcs['ST_Contains'] = [
'params' => 2,
'type' => 'int'
'type' => 'int',
];
$funcs['ST_Disjoint'] = [
'params' => 2,
'type' => 'int'
'type' => 'int',
];
$funcs['ST_Equals'] = [
'params' => 2,
'type' => 'int'
'type' => 'int',
];
$funcs['ST_Intersects'] = [
'params' => 2,
'type' => 'int'
'type' => 'int',
];
$funcs['ST_Overlaps'] = [
'params' => 2,
'type' => 'int'
'type' => 'int',
];
$funcs['ST_Touches'] = [
'params' => 2,
'type' => 'int'
'type' => 'int',
];
$funcs['ST_Within'] = [
'params' => 2,
'type' => 'int'
'type' => 'int',
];
}
@ -3810,31 +3810,31 @@ class Util
// Minimum bounding rectangle functions
$funcs['MBRContains'] = [
'params' => 2,
'type' => 'int'
'type' => 'int',
];
$funcs['MBRDisjoint'] = [
'params' => 2,
'type' => 'int'
'type' => 'int',
];
$funcs['MBREquals'] = [
'params' => 2,
'type' => 'int'
'type' => 'int',
];
$funcs['MBRIntersects'] = [
'params' => 2,
'type' => 'int'
'type' => 'int',
];
$funcs['MBROverlaps'] = [
'params' => 2,
'type' => 'int'
'type' => 'int',
];
$funcs['MBRTouches'] = [
'params' => 2,
'type' => 'int'
'type' => 'int',
];
$funcs['MBRWithin'] = [
'params' => 2,
'type' => 'int'
'type' => 'int',
];
}
return $funcs;

View File

@ -3148,7 +3148,7 @@ $cfg['ShowGitRevision'] = true;
*/
$cfg['MysqlMinVersion'] = [
'internal' => 50500,
'human' => '5.5.0'
'human' => '5.5.0',
];
/**

View File

@ -228,7 +228,7 @@ for ($columnNumber = 0; $columnNumber < $num_fields; $columnNumber++) {
'index' => 'MUL',
'unique' => 'UNI',
'fulltext' => 'FULLTEXT',
'spatial' => 'SPATIAL'
'spatial' => 'SPATIAL',
],
$parts[0],
''
@ -474,7 +474,7 @@ for ($columnNumber = 0; $columnNumber < $num_fields; $columnNumber++) {
'move_columns' => $move_columns,
'cfg_relation' => $cfgRelation,
'available_mime' => $available_mime,
'mime_map' => isset($mime_map) ? $mime_map : []
'mime_map' => isset($mime_map) ? $mime_map : [],
];
} // end for

View File

@ -133,7 +133,7 @@ if (isset($_POST['submit_export'])
'form_errors' => $form_display->displayErrors(),
'json' => $json,
'import_merge' => isset($_POST['import_merge']) ? $_POST['import_merge'] : null,
'return_url' => $return_url
'return_url' => $return_url,
]);
exit;
}

View File

@ -28,7 +28,7 @@ $dependency_definitions = [
'table' => $container->get('table'),
'sql_query' => &$GLOBALS['sql_query'],
'url_query' => &$GLOBALS['url_query'],
'cfg' => &$GLOBALS['cfg']
'cfg' => &$GLOBALS['cfg'],
];
/** @var Definition $definition */

View File

@ -32,7 +32,7 @@ $dependency_definitions = [
'db' => $container->get('db'),
'table' => $container->get('table'),
'searchType' => 'replace',
'url_query' => &$url_query
'url_query' => &$url_query,
];
/** @var Definition $definition */

View File

@ -33,7 +33,7 @@ $dependency_definitions = [
'db' => $container->get('db'),
'table' => $container->get('table'),
'searchType' => 'normal',
'url_query' => &$url_query
'url_query' => &$url_query,
];
/** @var Definition $definition */

View File

@ -55,7 +55,7 @@ $dependency_definitions = [
'tbl_storage_engine' => $tbl_storage_engine,
'table_info_num_rows' => $table_info_num_rows,
'tbl_collation' => $tbl_collation,
'showtable' => $GLOBALS['showtable']
'showtable' => $GLOBALS['showtable'],
];
/** @var Definition $definition */

View File

@ -32,7 +32,7 @@ $dependency_definitions = [
'db' => $container->get('db'),
'table' => $container->get('table'),
'searchType' => 'zoom',
'url_query' => &$url_query
'url_query' => &$url_query,
];
/** @var Definition $definition */

View File

@ -54,7 +54,7 @@ $test_defaults = [
'TESTSUITE_BROWSERSTACK_USER' => '',
'TESTSUITE_BROWSERSTACK_KEY' => '',
'TESTSUITE_FULL' => '',
'CI_MODE' => ''
'CI_MODE' => '',
];
if (PHP_SAPI == 'cli') {
foreach ($test_defaults as $varname => $defvalue) {

View File

@ -305,7 +305,7 @@ class AdvisorTest extends PmaTestCase
'issue' => 'official MySQL binaries.',
'recommendation' => 'See <a href="./url.php?url=https%3A%2F%2F' .
'example.com%2F" target="_blank" rel="noopener noreferrer">web</a>',
'id' => 'Distribution'
'id' => 'Distribution',
],
null,
],
@ -322,7 +322,7 @@ class AdvisorTest extends PmaTestCase
'issue' => 'official MySQL binaries.',
'recommendation' => 'See <a href="./url.php?url=https%3A%2F%2F' .
'example.com%2F" target="_blank" rel="noopener noreferrer">web</a>',
'id' => 'Distribution'
'id' => 'Distribution',
],
null,
],
@ -339,7 +339,7 @@ class AdvisorTest extends PmaTestCase
'issue' => 'official MySQL binaries.',
'recommendation' => 'See <a href="./url.php?url=https%3A%2F%2F' .
'example.com%2F" target="_blank" rel="noopener noreferrer">web</a>',
'id' => 'Distribution'
'id' => 'Distribution',
],
null,
],
@ -356,7 +356,7 @@ class AdvisorTest extends PmaTestCase
'issue' => 'official MySQL binaries.',
'recommendation' => 'See <a href="./url.php?url=https%3A%2F%2F' .
'example.com%2F" target="_blank" rel="noopener noreferrer">web</a>',
'id' => 'Distribution'
'id' => 'Distribution',
],
null,
],

View File

@ -118,7 +118,7 @@ class CentralColumnsTest extends TestCase
'relwork' => 1,
'db' => 'phpmyadmin',
'relation' => 'relation',
'central_columns' => 'pma_central_columns'
'central_columns' => 'pma_central_columns',
];
// mock DBI

View File

@ -97,7 +97,7 @@ class ConfigFileTest extends PmaTestCase
$default_config = [
self::SIMPLE_KEY_WITH_DEFAULT_VALUE => $default_simple_value,
'Servers/1/host' => $default_host,
'Servers/2/host' => $default_host
'Servers/2/host' => $default_host,
];
/**
@ -198,7 +198,7 @@ class ConfigFileTest extends PmaTestCase
1 => [
'passthrough1' => 1,
'passthrough2' => 2,
'value1' => 3
'value1' => 3,
],
],
],
@ -522,7 +522,7 @@ class ConfigFileTest extends PmaTestCase
"auth_type" => "config",
"user" => "testUser",
"host" => "example.com",
"port" => "21"
"port" => "21",
],
],
]
@ -559,7 +559,7 @@ class ConfigFileTest extends PmaTestCase
"user" => "testUser",
"host" => "example.com",
"port" => "21",
"password" => "testPass"
"password" => "testPass",
],
],
]
@ -616,7 +616,7 @@ class ConfigFileTest extends PmaTestCase
'Array/test' => [
'x',
'y',
]
],
],
$this->object->getConfigArray()
);

View File

@ -86,7 +86,7 @@ class FormDisplayTest extends PmaTestCase
"Servers" => [
"1" => [
'test' => 1,
1 => ':group:end'
1 => ':group:end',
],
],
];
@ -184,7 +184,7 @@ class FormDisplayTest extends PmaTestCase
"foobar" => [
'e2',
'e3',
]
],
];
$sysArr = [

View File

@ -124,7 +124,7 @@ class FormTest extends PmaTestCase
[
'auto' => 'auto',
'1' => 1,
'0' => 0
'0' => 0,
],
$this->object->getOptionValueList("OBGzip")
);
@ -134,7 +134,7 @@ class FormTest extends PmaTestCase
'none' => 'Nowhere',
'left' => 'Left',
'right' => 'Right',
'both' => "Both"
'both' => "Both",
],
$this->object->getOptionValueList("RowActionLinks")
);
@ -155,7 +155,7 @@ class FormTest extends PmaTestCase
"foo" => [
"bar" => [
'test' => 1,
1 => ':group:end'
1 => ':group:end',
],
],
];
@ -207,7 +207,7 @@ class FormTest extends PmaTestCase
"foo" => [
"bar" => [
'test' => 1,
1 => ':group:end'
1 => ':group:end',
],
],
];
@ -262,7 +262,7 @@ class FormTest extends PmaTestCase
"pma_form1" => "Servers/1/port",
"pma_form2" => "Servers/1/auth_type",
":group:end:0" => "preffoo/foo/bar/test",
"1" => "preffoo/foo/bar/:group:end:0"
"1" => "preffoo/foo/bar/:group:end:0",
];
$attrFieldsTypes = $reflection->getProperty('_fieldsTypes');
@ -275,7 +275,7 @@ class FormTest extends PmaTestCase
"pma_form1" => "integer",
"pma_form2" => "select",
":group:end:0" => "group",
"1" => "NULL"
"1" => "NULL",
],
$attrFieldsTypes->getValue($this->object)
);

View File

@ -1383,7 +1383,7 @@ class ConfigTest extends PmaTestCase
[1 => ['host' => '']],
[
'verbose' => 'Server 1',
'host' => ''
'host' => '',
],
],
'invalid' => [
@ -1441,7 +1441,7 @@ class ConfigTest extends PmaTestCase
[
1 => [
'verbose' => 'Server 1',
'host' => ''
'host' => '',
],
],
'Server 1',
@ -1451,7 +1451,7 @@ class ConfigTest extends PmaTestCase
[
66 => [
'verbose' => 'Server 1',
'host' => ''
'host' => '',
],
],
'753f173bd4ac8a45eae0fe9a4fbe0fc0',

View File

@ -133,7 +133,7 @@ class StructureControllerTest extends PmaTestCase
'TABLE_ROWS' => 5,
'Data_length' => 16384,
'Index_length' => 0,
'TABLE_NAME' => 'table'
'TABLE_NAME' => 'table',
];
list($currentTable,,, $sumSize) = $method->invokeArgs(
$controller,
@ -359,7 +359,7 @@ class StructureControllerTest extends PmaTestCase
// Correct parameter
$tables = [
'db.table'
'db.table',
];
$this->assertEquals(
true,
@ -368,7 +368,7 @@ class StructureControllerTest extends PmaTestCase
// Table not in database
$tables = [
'db.tab1e'
'db.tab1e',
];
$this->assertEquals(
false,

View File

@ -137,7 +137,7 @@ class EnginesControllerTest extends TestCase
$this->assertStringContainsString(
Url::getCommon([
'engine' => 'Pbxt',
'page' => 'Documentation'
'page' => 'Documentation',
]),
$actual
);

View File

@ -247,11 +247,11 @@ class MonitorControllerTest extends TestCase
$resultRows = [
[
'sql_text' => 'insert sql_text',
'#' => 11
'#' => 11,
],
[
'sql_text' => 'update sql_text',
'#' => 10
'#' => 10,
],
];
$resultSum = [

View File

@ -228,7 +228,7 @@ class ProcessesControllerTest extends TestCase
'Command' => 'Command1',
'Info' => 'Info1',
'State' => 'State1',
'Time' => 'Time1'
'Time' => 'Time1',
];
$GLOBALS['cfg']['MaxCharactersInDisplayedSQL'] = 12;
$GLOBALS['dbi']->expects($this->any())->method('fetchAssoc')

View File

@ -58,7 +58,7 @@ class VariablesControllerTest extends TestCase
$serverGlobalVariables = [
'auto_increment_increment' => '0',
'auto_increment_offset' => '12'
'auto_increment_offset' => '12',
];
$fetchResult = [

View File

@ -151,7 +151,7 @@ class RelationControllerTest extends PmaTestCase
public function testGetDropdownValueForTableActionNotView()
{
$indexedColumns = [
'primaryTableCol'
'primaryTableCol',
];
$tableMock = $this->getMockBuilder('PhpMyAdmin\Table')
->disableOriginalConstructor()
@ -198,7 +198,7 @@ class RelationControllerTest extends PmaTestCase
$count++;
return [
'Engine' => 'InnoDB',
'Name' => 'table'
'Name' => 'table',
];
}
return null;

View File

@ -82,7 +82,7 @@ class CoreTest extends PmaTestCase
'b',
'c',
], 4,
]
],
],
];
@ -185,7 +185,7 @@ class CoreTest extends PmaTestCase
'b',
'c',
], 4,
]
],
],
];
@ -254,7 +254,7 @@ class CoreTest extends PmaTestCase
'b',
'c',
], 4,
]
],
],
];

View File

@ -50,7 +50,7 @@ class DesignerTest extends TestCase
'PMA_VERSION' => PMA_VERSION,
'db' => 'pmadb',
'pdf_pages' => 'pdf_pages',
'pdfwork' => true
'pdfwork' => true,
],
],
' PMA_token ' => 'token',

View File

@ -342,7 +342,7 @@ class QbeTest extends PmaTestCase
3,
[
'and' => '',
'or' => ' checked="checked"'
'or' => ' checked="checked"',
],
]
)
@ -461,7 +461,7 @@ class QbeTest extends PmaTestCase
$this->assertEquals(
[
'unique' => [],
'index' => []
'index' => [],
],
$this->_callProtectedFunction(
'_getIndexes',

View File

@ -155,7 +155,7 @@ class SearchTest extends PmaTestCase
'select_columns' => 'SELECT * FROM `pma`.`table1` WHERE FALSE',
'select_count' => 'SELECT COUNT(*) AS `count` FROM `pma`.`table1` ' .
'WHERE FALSE',
'delete' => 'DELETE FROM `pma`.`table1` WHERE FALSE'
'delete' => 'DELETE FROM `pma`.`table1` WHERE FALSE',
],
$this->callProtectedFunction(
'getSearchSqls',

View File

@ -157,7 +157,7 @@ class DatabaseInterfaceTest extends PmaTestCase
[
'table_name' => 'meta1_table',
'refering_column' => 'meta1_name',
'real_column' => 'view_columns1'
'real_column' => 'view_columns1',
],
$column_map[0]
);
@ -165,7 +165,7 @@ class DatabaseInterfaceTest extends PmaTestCase
[
'table_name' => 'meta2_table',
'refering_column' => 'meta2_name',
'real_column' => 'view_columns2'
'real_column' => 'view_columns2',
],
$column_map[1]
);

View File

@ -1028,7 +1028,7 @@ class ResultsTest extends PmaTestCase
[
'routine_name' => 'circumference',
'routine_schema' => 'data',
'routine_type' => 'FUNCTION'
'routine_type' => 'FUNCTION',
],
'routine_name',
'db_routines.php?item_name=circumference&db=data'
@ -1041,7 +1041,7 @@ class ResultsTest extends PmaTestCase
[
'routine_name' => 'area',
'routine_schema' => 'data',
'routine_type' => 'PROCEDURE'
'routine_type' => 'PROCEDURE',
],
'routine_name',
'db_routines.php?item_name=area&db=data'
@ -1053,7 +1053,7 @@ class ResultsTest extends PmaTestCase
'CHARACTER_SET_NAME',
[
'table_schema' => 'information_schema',
'table_name' => 'CHARACTER_SETS'
'table_name' => 'CHARACTER_SETS',
],
'column_name',
'index.php?sql_query=SELECT+%60CHARACTER_SET_NAME%60+FROM+%60info'
@ -1101,7 +1101,7 @@ class ResultsTest extends PmaTestCase
'column_name' => 'routine_type',
],
],
'default_page' => 'db_routines.php'
'default_page' => 'db_routines.php',
],
],
'columns' => [
@ -1123,9 +1123,9 @@ class ResultsTest extends PmaTestCase
],
],
],
'default_page' => 'index.php'
'default_page' => 'index.php',
],
]
],
],
];
@ -1188,7 +1188,7 @@ class ResultsTest extends PmaTestCase
'host' => 'localhost',
'select_privilages' => 'Y',
'db' => 'phpmyadmin',
'user' => 'pmauser'
'user' => 'pmauser',
],
],
];

View File

@ -167,7 +167,7 @@ class InnodbTest extends PmaTestCase
$this->assertEquals(
[
'Bufferpool' => 'Buffer Pool',
'Status' => 'InnoDB Status'
'Status' => 'InnoDB Status',
],
$this->object->getInfoPages()
);

View File

@ -99,7 +99,7 @@ class ErrorReportTest extends TestCase
'type' => $_SESSION['prev_errors'][0]->getType(),
'msg' => $_SESSION['prev_errors'][0]->getOnlyMessage(),
'stackTrace' => $_SESSION['prev_errors'][0]->getBacktrace(5),
'stackhash' => $_SESSION['prev_errors'][0]->getHash()
'stackhash' => $_SESSION['prev_errors'][0]->getHash(),
],
1 => [
'lineNum' => $_SESSION['prev_errors'][1]->getLine(),
@ -107,7 +107,7 @@ class ErrorReportTest extends TestCase
'type' => $_SESSION['prev_errors'][1]->getType(),
'msg' => $_SESSION['prev_errors'][1]->getOnlyMessage(),
'stackTrace' => $_SESSION['prev_errors'][1]->getBacktrace(5),
'stackhash' => $_SESSION['prev_errors'][1]->getHash()
'stackhash' => $_SESSION['prev_errors'][1]->getHash(),
],
],
];
@ -182,7 +182,7 @@ class ErrorReportTest extends TestCase
'context' => $context,
],
],
'url' => 'http://pma.7.3.local/tbl_sql.php?db=aaaaa&table=a&server=14'
'url' => 'http://pma.7.3.local/tbl_sql.php?db=aaaaa&table=a&server=14',
];
$_POST['microhistory'] = '';
$_POST['description'] = 'description';
@ -213,7 +213,7 @@ class ErrorReportTest extends TestCase
'scriptname' => 'js/vendor/codemirror/addon/hint/show-hint.js',
],
],
'uri' => 'tbl_sql.php?'
'uri' => 'tbl_sql.php?',
],
'microhistory' => $_POST['microhistory'],
'steps' => $_POST['description'],

View File

@ -62,7 +62,7 @@ class ErrorTest extends PmaTestCase
'file' => 'bt1',
'line' => 2,
'function' => 'bar',
'args' => ['foo' => $this]
'args' => ['foo' => $this],
],
];
$this->object->setBacktrace($bt);
@ -191,25 +191,25 @@ class ErrorTest extends PmaTestCase
'file' => 'bt1',
'line' => 2,
'function' => 'bar',
'args' => ['foo' => 1]
'args' => ['foo' => 1],
],
[
'file' => 'bt2',
'line' => 2,
'function' => 'bar',
'args' => ['foo' => 2]
'args' => ['foo' => 2],
],
[
'file' => 'bt3',
'line' => 2,
'function' => 'bar',
'args' => ['foo' => 3]
'args' => ['foo' => 3],
],
[
'file' => 'bt4',
'line' => 2,
'function' => 'bar',
'args' => ['foo' => 4]
'args' => ['foo' => 4],
],
];

View File

@ -133,7 +133,7 @@ class FooterTest extends PmaTestCase
$this->_callPrivateFunction(
'_removeRecursion',
[
&$object
&$object,
]
);
@ -162,7 +162,7 @@ class FooterTest extends PmaTestCase
$this->_callPrivateFunction(
'_getSelfLink',
[
$this->object->getSelfUrl()
$this->object->getSelfUrl(),
]
)
);
@ -189,7 +189,7 @@ class FooterTest extends PmaTestCase
$this->_callPrivateFunction(
'_getSelfLink',
[
$this->object->getSelfUrl()
$this->object->getSelfUrl(),
]
)
);

View File

@ -124,7 +124,7 @@ class GisGeometryCollectionTest extends TestCase
1 => [
'x' => 6.14,
'y' => 0.15,
]
],
],
],
];
@ -178,9 +178,9 @@ class GisGeometryCollectionTest extends TestCase
'1' => [
'x' => 6.14,
'y' => 0.15,
]
],
],
]
],
],
],
];

View File

@ -68,7 +68,7 @@ class GisLineStringTest extends GisGeomTestCase
1 => [
'x' => 6.14,
'y' => 0.15,
]
],
],
],
];
@ -132,7 +132,7 @@ class GisLineStringTest extends GisGeomTestCase
1 => [
'x' => '6.14',
'y' => '0.15',
]
],
],
];
$temp1 = $temp;
@ -144,7 +144,7 @@ class GisLineStringTest extends GisGeomTestCase
null,
[
'srid' => '124',
0 => $temp
0 => $temp,
],
],
[

View File

@ -70,7 +70,7 @@ class GisMultiLineStringTest extends GisGeomTestCase
1 => [
'x' => 6.14,
'y' => 0.15,
]
],
],
1 => [
'no_of_points' => 2,
@ -81,8 +81,8 @@ class GisMultiLineStringTest extends GisGeomTestCase
1 => [
'x' => 9.15,
'y' => 0.47,
]
]
],
],
],
],
];
@ -215,7 +215,7 @@ class GisMultiLineStringTest extends GisGeomTestCase
'x' => 9.15,
'y' => 0.47,
],
]
],
],
];
@ -228,7 +228,7 @@ class GisMultiLineStringTest extends GisGeomTestCase
null,
[
'srid' => '124',
0 => $temp
0 => $temp,
],
],
[

View File

@ -68,7 +68,7 @@ class GisMultiPointTest extends GisGeomTestCase
1 => [
'x' => 1.56,
'y' => 4.36,
]
],
],
],
];
@ -110,7 +110,7 @@ class GisMultiPointTest extends GisGeomTestCase
'x' => 6.14,
'y' => 0.15,
],
]
],
];
$this->assertEquals(
@ -136,7 +136,7 @@ class GisMultiPointTest extends GisGeomTestCase
1 => [
'x' => '6.14',
'y' => '0.15',
]
],
],
];
$temp2 = $temp1;
@ -148,7 +148,7 @@ class GisMultiPointTest extends GisGeomTestCase
null,
[
'srid' => '124',
0 => $temp1
0 => $temp1,
],
],
[

View File

@ -103,7 +103,7 @@ class GisMultiPolygonTest extends GisGeomTestCase
'x' => 20,
'y' => 30,
],
]
],
],
1 => [
'no_of_lines' => 1,
@ -125,8 +125,8 @@ class GisMultiPolygonTest extends GisGeomTestCase
'x' => 123,
'y' => 0,
],
]
]
],
],
],
];
}
@ -205,7 +205,7 @@ class GisMultiPolygonTest extends GisGeomTestCase
null,
[
'srid' => '124',
0 => $temp
0 => $temp,
],
],
[

View File

@ -154,7 +154,7 @@ class GisPointTest extends GisGeomTestCase
'POINT' => [
'x' => '5.02',
'y' => '8.45',
]
],
],
],
],

View File

@ -101,7 +101,7 @@ class GisPolygonTest extends GisGeomTestCase
'x' => 20,
'y' => 30,
],
]
],
],
];
}
@ -190,7 +190,7 @@ class GisPolygonTest extends GisGeomTestCase
null,
[
'srid' => '124',
0 => $temp
0 => $temp,
],
],
[
@ -401,10 +401,10 @@ class GisPolygonTest extends GisGeomTestCase
return [
[
$temp['POLYGON'][0]
$temp['POLYGON'][0],
],
[
$temp['POLYGON'][1]
$temp['POLYGON'][1],
],
];
}

View File

@ -43,21 +43,21 @@ class IndexTest extends PmaTestCase
"Seq_in_index" => "index1",
"Collation" => "Collation1",
"Cardinality" => "Cardinality1",
"Null" => "null1"
"Null" => "null1",
];
$column2 = [
"Column_name" => "column2",
"Seq_in_index" => "index2",
"Collation" => "Collation2",
"Cardinality" => "Cardinality2",
"Null" => "null2"
"Null" => "null2",
];
$column3 = [
"Column_name" => "column3",
"Seq_in_index" => "index3",
"Collation" => "Collation3",
"Cardinality" => "Cardinality3",
"Null" => "null3"
"Null" => "null3",
];
$this->_params['columns'][] = $column1;
$this->_params['columns'][] = $column2;

View File

@ -100,7 +100,7 @@ class InsertEditTest extends TestCase
{
$where_clause = [
'foo' => 'bar ',
'1' => ' test'
'1' => ' test',
];
$_POST['clause_is_unique'] = false;
$_POST['sql_query'] = 'SELECT a';
@ -123,7 +123,7 @@ class InsertEditTest extends TestCase
'sql_query' => 'SELECT a',
'where_clause[foo]' => 'bar',
'where_clause[1]' => 'test',
'clause_is_unique' => false
'clause_is_unique' => false,
],
$result
);
@ -341,7 +341,7 @@ class InsertEditTest extends TestCase
[
'0' => 1,
'where_clause' => 'bar=2',
'sql_query' => 'SELECT 1'
'sql_query' => 'SELECT 1',
],
$result
);
@ -408,7 +408,7 @@ class InsertEditTest extends TestCase
$column = [
'Field' => '1<2',
'Field_md5' => 'pswd',
'Type' => 'float(10, 1)'
'Type' => 'float(10, 1)',
];
$result = $this->callProtectedMethod('analyzeTableColumnsArray', [
@ -1229,11 +1229,11 @@ class InsertEditTest extends TestCase
[
[
'plain' => '<abc>',
'html' => '&lt;abc&gt;'
'html' => '&lt;abc&gt;',
],
[
'plain' => '"foo"',
'html' => '&quot;foo&quot;'
'html' => '&quot;foo&quot;',
],
],
$result
@ -1468,11 +1468,11 @@ class InsertEditTest extends TestCase
[
[
'plain' => 'a',
'html' => 'a'
'html' => 'a',
],
[
'plain' => '<',
'html' => '&lt;'
'html' => '&lt;',
],
],
2,
@ -2175,7 +2175,7 @@ class InsertEditTest extends TestCase
$url_params = ['ShowFunctionFields' => 2];
$result = $this->callProtectedMethod('getHeadAndFootOfInsertRowTable', [
$url_params
$url_params,
]);
$this->assertStringContainsString(
@ -3681,7 +3681,7 @@ class InsertEditTest extends TestCase
[
[
'Comment' => 'b',
'Field' => 'd'
'Field' => 'd',
],
]
)
@ -3725,7 +3725,7 @@ class InsertEditTest extends TestCase
[
'db' => 'foo',
'sql_query' => 'SELECT',
'table' => 'bar'
'table' => 'bar',
],
$this->insertEdit->getUrlParameters('foo', 'bar')
);

View File

@ -421,7 +421,7 @@ class NormalizationTest extends TestCase
'table2' => [
'pk' => 'id',
'nonpk' => 'col4, col5',
]
],
],
],
$result1['newTables']
@ -445,7 +445,7 @@ class NormalizationTest extends TestCase
$newTables = [
'PMA_table' => [
'PMA_table' => $cols,
'table1' => $cols1
'table1' => $cols1,
],
];
$result = $this->normalization->createNewTablesFor3NF(
@ -547,7 +547,7 @@ class NormalizationTest extends TestCase
$choices = [
'1nf' => __('First step of normalization (1NF)'),
'2nf' => __('Second step of normalization (1NF+2NF)'),
'3nf' => __('Third step of normalization (1NF+2NF+3NF)')
'3nf' => __('Third step of normalization (1NF+2NF+3NF)'),
];
$htmlTmp = Util::getRadioFields(

View File

@ -679,7 +679,7 @@ class AuthenticationCookieTest extends PmaTestCase
'port' => 1,
'socket' => true,
'ssl' => true,
'user' => 'pmaUser2'
'user' => 'pmaUser2',
];
$GLOBALS['cfg']['Server'] = $arr;
@ -728,7 +728,7 @@ class AuthenticationCookieTest extends PmaTestCase
'port' => 1,
'socket' => true,
'ssl' => true,
'user' => 'pmaUser2'
'user' => 'pmaUser2',
];
$GLOBALS['cfg']['Server'] = $arr;
@ -1109,7 +1109,7 @@ class AuthenticationCookieTest extends PmaTestCase
$payload = [
'password' => $newPassword,
'server' => 'b 2'
'server' => 'b 2',
];
$method = new ReflectionMethod(
'PhpMyAdmin\Plugins\Auth\AuthenticationCookie',

View File

@ -352,7 +352,7 @@ class AuthenticationHttpTest extends PmaTestCase
$GLOBALS['cfg']['Servers'][1] = [
'host' => 'a',
'user' => 'testUser',
'foo' => 'bar'
'foo' => 'bar',
];
$GLOBALS['cfg']['Server'] = [
@ -385,7 +385,7 @@ class AuthenticationHttpTest extends PmaTestCase
$GLOBALS['cfg']['Servers'][1] = [
'host' => 'a',
'user' => 'testUsers',
'foo' => 'bar'
'foo' => 'bar',
];
$GLOBALS['cfg']['Server'] = [
@ -401,7 +401,7 @@ class AuthenticationHttpTest extends PmaTestCase
[
'user' => 'testUser',
'password' => 'testPass',
'host' => 'a'
'host' => 'a',
],
$GLOBALS['cfg']['Server']
);

View File

@ -493,7 +493,7 @@ class ExportHtmlwordTest extends PmaTestCase
'fieldname' => [
'values' => 'test-',
'transformation' => 'testfoo',
'mimetype' => 'test<'
'mimetype' => 'test<',
],
]
);
@ -589,7 +589,7 @@ class ExportHtmlwordTest extends PmaTestCase
'field' => [
'values' => 'test-',
'transformation' => 'testfoo',
'mimetype' => 'test<'
'mimetype' => 'test<',
],
]
);
@ -747,7 +747,7 @@ class ExportHtmlwordTest extends PmaTestCase
'name' => 'tna"me',
'action_timing' => 'ac>t',
'event_manipulation' => 'manip&',
'definition' => 'def'
'definition' => 'def',
],
];
@ -904,11 +904,11 @@ class ExportHtmlwordTest extends PmaTestCase
'Null' => 'Yes',
'Field' => 'field',
'Key' => 'PRI',
'Type' => 'set(abc)enum123'
'Type' => 'set(abc)enum123',
];
$unique_keys = [
'field'
'field',
];
$this->assertEquals(
@ -927,7 +927,7 @@ class ExportHtmlwordTest extends PmaTestCase
];
$unique_keys = [
'field'
'field',
];
$this->assertEquals(

View File

@ -700,7 +700,7 @@ class ExportLatexTest extends PmaTestCase
'name1' => [
'values' => 'test-',
'transformation' => 'testfoo',
'mimetype' => 'testmimetype_'
'mimetype' => 'testmimetype_',
],
]
);
@ -710,7 +710,7 @@ class ExportLatexTest extends PmaTestCase
'Null' => 'Yes',
'Field' => 'name1',
'Key' => 'PRI',
'Type' => 'set(abc)enum123'
'Type' => 'set(abc)enum123',
],
[
'Null' => 'NO',
@ -820,7 +820,7 @@ class ExportLatexTest extends PmaTestCase
'field' => [
'values' => 'test-',
'transformation' => 'testfoo',
'mimetype' => 'test<'
'mimetype' => 'test<',
],
]
);

View File

@ -274,7 +274,7 @@ class ExportMediawikiTest extends PmaTestCase
'Key' => 'PRI',
'Type' => 'set(abc)enum123',
'Default' => '',
'Extra' => ''
'Extra' => '',
],
[
'Null' => 'NO',
@ -282,7 +282,7 @@ class ExportMediawikiTest extends PmaTestCase
'Key' => 'COMP',
'Type' => '',
'Default' => 'def',
'Extra' => 'ext'
'Extra' => 'ext',
],
];

View File

@ -716,7 +716,7 @@ class ExportOdtTest extends PmaTestCase
'fieldname' => [
'values' => 'test-',
'transformation' => 'testfoo',
'mimetype' => 'test<'
'mimetype' => 'test<',
],
]
);
@ -822,7 +822,7 @@ class ExportOdtTest extends PmaTestCase
'field' => [
'values' => 'test-',
'transformation' => 'testfoo',
'mimetype' => 'test<'
'mimetype' => 'test<',
],
]
);
@ -902,7 +902,7 @@ class ExportOdtTest extends PmaTestCase
'name' => 'tna"me',
'action_timing' => 'ac>t',
'event_manipulation' => 'manip&',
'definition' => 'def'
'definition' => 'def',
],
];
@ -1096,7 +1096,7 @@ class ExportOdtTest extends PmaTestCase
'Null' => 'Yes',
'Field' => 'field',
'Key' => 'PRI',
'Type' => 'set(abc)enum123'
'Type' => 'set(abc)enum123',
];
$col_alias = 'alias';

View File

@ -284,7 +284,7 @@ class ExportPdfTest extends PmaTestCase
'dbAlias' => 'db',
'tableAlias' => 'table',
'aliases' => [],
'purpose' => __('Dumping data')
'purpose' => __('Dumping data'),
]
);

View File

@ -873,7 +873,7 @@ class ExportSqlTest extends PmaTestCase
'Null' => 'NO',
'Default' => 'a',
'Comment' => 'cmt',
'Field' => 'fname'
'Field' => 'fname',
],
]
)
@ -918,7 +918,7 @@ class ExportSqlTest extends PmaTestCase
'Collation' => 'utf-8',
'Null' => 'YES',
'Comment' => 'cmt',
'Field' => 'fname'
'Field' => 'fname',
],
]
)
@ -1264,7 +1264,7 @@ class ExportSqlTest extends PmaTestCase
'fieldname' => [
'values' => 'test-',
'transformation' => 'testfoo',
'mimetype' => 'test<'
'mimetype' => 'test<',
],
]
);
@ -1321,7 +1321,7 @@ class ExportSqlTest extends PmaTestCase
[
[
'create' => 'bar',
'drop' => 'foo'
'drop' => 'foo',
],
]
)

View File

@ -405,7 +405,7 @@ class ExportTexytextTest extends PmaTestCase
'fname' => [
'values' => 'test-',
'transformation' => 'testfoo',
'mimetype' => 'test<'
'mimetype' => 'test<',
],
]
);
@ -479,7 +479,7 @@ class ExportTexytextTest extends PmaTestCase
'name' => 'tna"me',
'action_timing' => 'ac>t',
'event_manipulation' => 'manip&',
'definition' => 'def'
'definition' => 'def',
],
];
@ -645,11 +645,11 @@ class ExportTexytextTest extends PmaTestCase
'Null' => 'Yes',
'Field' => 'field',
'Key' => 'PRI',
'Type' => 'set(abc)enum123'
'Type' => 'set(abc)enum123',
];
$unique_keys = [
'field'
'field',
];
$this->assertEquals(
@ -666,7 +666,7 @@ class ExportTexytextTest extends PmaTestCase
];
$unique_keys = [
'field'
'field',
];
$this->assertEquals(

View File

@ -251,7 +251,7 @@ class ExportXmlTest extends PmaTestCase
[
[
'create' => 'crt',
'name' => 'trname'
'name' => 'trname',
],
]
)
@ -261,10 +261,10 @@ class ExportXmlTest extends PmaTestCase
->method('getProceduresOrFunctions')
->willReturnOnConsecutiveCalls(
[
'fn'
'fn',
],
[
'pr'
'pr',
]
);

View File

@ -54,7 +54,7 @@ class DiaRelationSchemaTest extends PmaTestCase
'db' => "information_schema",
'table_info' => 'table_info',
'relwork' => 'relwork',
'relation' => 'relation'
'relation' => 'relation',
];
$relation = new Relation($GLOBALS['dbi']);
$relation->getRelationsParam();

View File

@ -55,7 +55,7 @@ class EpsRelationSchemaTest extends PmaTestCase
'db' => "information_schema",
'table_info' => 'table_info',
'relwork' => 'relwork',
'relation' => 'relation'
'relation' => 'relation',
];
$relation = new Relation($GLOBALS['dbi']);
$relation->getRelationsParam();

View File

@ -67,7 +67,7 @@ class PdfRelationSchemaTest extends PmaTestCase
'mimework' => 'mimework',
'commwork' => 'commwork',
'column_info' => 'column_info',
'pdf_pages' => 'pdf_pages'
'pdf_pages' => 'pdf_pages',
];
$relation = new Relation($GLOBALS['dbi']);
$relation->getRelationsParam();

View File

@ -54,7 +54,7 @@ class SvgRelationSchemaTest extends PmaTestCase
'db' => "information_schema",
'table_info' => 'table_info',
'relwork' => 'relwork',
'relation' => 'relation'
'relation' => 'relation',
];
$relation = new Relation($GLOBALS['dbi']);
$relation->getRelationsParam();

View File

@ -320,7 +320,7 @@ class RelationTest extends TestCase
'value',
],
'on_delete' => 'CASCADE',
'on_update' => 'CASCADE'
'on_update' => 'CASCADE',
],
],
];

View File

@ -72,11 +72,11 @@ class ReplicationGuiTest extends TestCase
$slave_host = [
[
'Server_id' => 'Server_id1',
'Host' => 'Host1'
'Host' => 'Host1',
],
[
'Server_id' => 'Server_id2',
'Host' => 'Host2'
'Host' => 'Host2',
],
];

Some files were not shown because too many files have changed in this diff Show More