Remove __('Options')
It was not used anywhere. Signed-off-by: Kamil Tekiela <tekiela246@gmail.com>
This commit is contained in:
parent
71483428a2
commit
384f47ffc8
@ -55,7 +55,6 @@ class ExportCodegen extends ExportPlugin
|
||||
$exportPluginProperties->setText('CodeGen');
|
||||
$exportPluginProperties->setExtension('cs');
|
||||
$exportPluginProperties->setMimeType('text/cs');
|
||||
$exportPluginProperties->setOptionsText(__('Options'));
|
||||
|
||||
// create the root group that will be the options field for
|
||||
// $exportPluginProperties
|
||||
|
||||
@ -54,7 +54,6 @@ class ExportCsv extends ExportPlugin
|
||||
$exportPluginProperties->setText('CSV');
|
||||
$exportPluginProperties->setExtension('csv');
|
||||
$exportPluginProperties->setMimeType('text/comma-separated-values');
|
||||
$exportPluginProperties->setOptionsText(__('Options'));
|
||||
|
||||
// create the root group that will be the options field for
|
||||
// $exportPluginProperties
|
||||
|
||||
@ -55,7 +55,6 @@ class ExportExcel extends ExportPlugin
|
||||
$exportPluginProperties->setText('CSV for MS Excel');
|
||||
$exportPluginProperties->setExtension('csv');
|
||||
$exportPluginProperties->setMimeType('text/comma-separated-values');
|
||||
$exportPluginProperties->setOptionsText(__('Options'));
|
||||
|
||||
// create the root group that will be the options field for
|
||||
// $exportPluginProperties
|
||||
|
||||
@ -55,7 +55,6 @@ class ExportHtmlword extends ExportPlugin
|
||||
$exportPluginProperties->setExtension('doc');
|
||||
$exportPluginProperties->setMimeType('application/vnd.ms-word');
|
||||
$exportPluginProperties->setForceFile(true);
|
||||
$exportPluginProperties->setOptionsText(__('Options'));
|
||||
|
||||
// create the root group that will be the options field for
|
||||
// $exportPluginProperties
|
||||
|
||||
@ -70,7 +70,6 @@ class ExportJson extends ExportPlugin
|
||||
$exportPluginProperties->setText('JSON');
|
||||
$exportPluginProperties->setExtension('json');
|
||||
$exportPluginProperties->setMimeType('application/json');
|
||||
$exportPluginProperties->setOptionsText(__('Options'));
|
||||
|
||||
// create the root group that will be the options field for
|
||||
// $exportPluginProperties
|
||||
|
||||
@ -86,7 +86,6 @@ class ExportLatex extends ExportPlugin
|
||||
$exportPluginProperties->setText('LaTeX');
|
||||
$exportPluginProperties->setExtension('tex');
|
||||
$exportPluginProperties->setMimeType('application/x-tex');
|
||||
$exportPluginProperties->setOptionsText(__('Options'));
|
||||
|
||||
// create the root group that will be the options field for
|
||||
// $exportPluginProperties
|
||||
|
||||
@ -47,7 +47,6 @@ class ExportMediawiki extends ExportPlugin
|
||||
$exportPluginProperties->setText('MediaWiki Table');
|
||||
$exportPluginProperties->setExtension('mediawiki');
|
||||
$exportPluginProperties->setMimeType('text/plain');
|
||||
$exportPluginProperties->setOptionsText(__('Options'));
|
||||
|
||||
// create the root group that will be the options field for
|
||||
// $exportPluginProperties
|
||||
|
||||
@ -51,7 +51,6 @@ class ExportOds extends ExportPlugin
|
||||
$exportPluginProperties->setExtension('ods');
|
||||
$exportPluginProperties->setMimeType('application/vnd.oasis.opendocument.spreadsheet');
|
||||
$exportPluginProperties->setForceFile(true);
|
||||
$exportPluginProperties->setOptionsText(__('Options'));
|
||||
|
||||
// create the root group that will be the options field for
|
||||
// $exportPluginProperties
|
||||
|
||||
@ -62,7 +62,6 @@ class ExportOdt extends ExportPlugin
|
||||
$exportPluginProperties->setExtension('odt');
|
||||
$exportPluginProperties->setMimeType('application/vnd.oasis.opendocument.text');
|
||||
$exportPluginProperties->setForceFile(true);
|
||||
$exportPluginProperties->setOptionsText(__('Options'));
|
||||
|
||||
// create the root group that will be the options field for
|
||||
// $exportPluginProperties
|
||||
|
||||
@ -52,7 +52,6 @@ class ExportPdf extends ExportPlugin
|
||||
$exportPluginProperties->setExtension('pdf');
|
||||
$exportPluginProperties->setMimeType('application/pdf');
|
||||
$exportPluginProperties->setForceFile(true);
|
||||
$exportPluginProperties->setOptionsText(__('Options'));
|
||||
|
||||
// create the root group that will be the options field for
|
||||
// $exportPluginProperties
|
||||
|
||||
@ -20,7 +20,6 @@ use PhpMyAdmin\Properties\Plugins\ExportPluginProperties;
|
||||
use PhpMyAdmin\Util;
|
||||
use PhpMyAdmin\Version;
|
||||
|
||||
use function __;
|
||||
use function bin2hex;
|
||||
use function preg_match;
|
||||
use function preg_replace;
|
||||
@ -44,7 +43,6 @@ class ExportPhparray extends ExportPlugin
|
||||
$exportPluginProperties->setText('PHP array');
|
||||
$exportPluginProperties->setExtension('php');
|
||||
$exportPluginProperties->setMimeType('text/plain');
|
||||
$exportPluginProperties->setOptionsText(__('Options'));
|
||||
|
||||
// create the root group that will be the options field for
|
||||
// $exportPluginProperties
|
||||
|
||||
@ -166,8 +166,6 @@ class ExportSql extends ExportPlugin
|
||||
return $exportPluginProperties;
|
||||
}
|
||||
|
||||
$exportPluginProperties->setOptionsText(__('Options'));
|
||||
|
||||
// create the root group that will be the options field for
|
||||
// $exportPluginProperties
|
||||
// this will be shown as "Format specific options"
|
||||
|
||||
@ -54,7 +54,6 @@ class ExportTexytext extends ExportPlugin
|
||||
$exportPluginProperties->setText('Texy! text');
|
||||
$exportPluginProperties->setExtension('txt');
|
||||
$exportPluginProperties->setMimeType('text/plain');
|
||||
$exportPluginProperties->setOptionsText(__('Options'));
|
||||
|
||||
// create the root group that will be the options field for
|
||||
// $exportPluginProperties
|
||||
|
||||
@ -47,7 +47,6 @@ class ExportToon extends ExportPlugin
|
||||
$exportPluginProperties->setExtension('toon');
|
||||
$exportPluginProperties->setMimeType('text/toon');
|
||||
$exportPluginProperties->setForceFile(true);
|
||||
$exportPluginProperties->setOptionsText(__('Options'));
|
||||
|
||||
// create the root group that will be the options field for
|
||||
// $exportPluginProperties
|
||||
|
||||
@ -66,7 +66,6 @@ class ExportXml extends ExportPlugin
|
||||
$exportPluginProperties->setText('XML');
|
||||
$exportPluginProperties->setExtension('xml');
|
||||
$exportPluginProperties->setMimeType('text/xml');
|
||||
$exportPluginProperties->setOptionsText(__('Options'));
|
||||
|
||||
// create the root group that will be the options field for
|
||||
// $exportPluginProperties
|
||||
|
||||
@ -19,7 +19,6 @@ use PhpMyAdmin\Properties\Options\Groups\OptionsPropertyRootGroup;
|
||||
use PhpMyAdmin\Properties\Options\Items\HiddenPropertyItem;
|
||||
use PhpMyAdmin\Properties\Plugins\ExportPluginProperties;
|
||||
|
||||
use function __;
|
||||
use function array_key_exists;
|
||||
use function bin2hex;
|
||||
use function is_numeric;
|
||||
@ -43,7 +42,6 @@ class ExportYaml extends ExportPlugin
|
||||
$exportPluginProperties->setExtension('yml');
|
||||
$exportPluginProperties->setMimeType('text/yaml');
|
||||
$exportPluginProperties->setForceFile(true);
|
||||
$exportPluginProperties->setOptionsText(__('Options'));
|
||||
|
||||
// create the root group that will be the options field for
|
||||
// $exportPluginProperties
|
||||
|
||||
@ -67,7 +67,6 @@ class Export[Name] extends PhpMyAdmin\Plugins\ExportPlugin
|
||||
$exportPluginProperties = new PhpMyAdmin\Properties\Plugins\ExportPluginProperties();
|
||||
$exportPluginProperties->setText('[name]'); // the name of your plug-in
|
||||
$exportPluginProperties->setExtension('[ext]'); // extension this plug-in can handle
|
||||
$exportPluginProperties->setOptionsText(__('Options'));
|
||||
|
||||
// create the root group that will be the options field for
|
||||
// $exportPluginProperties
|
||||
|
||||
@ -77,7 +77,6 @@ class ImportCsv extends AbstractImportCsv
|
||||
$importPluginProperties = new ImportPluginProperties();
|
||||
$importPluginProperties->setText('CSV');
|
||||
$importPluginProperties->setExtension('csv');
|
||||
$importPluginProperties->setOptionsText(__('Options'));
|
||||
|
||||
// create the root group that will be the options field for
|
||||
// $importPluginProperties
|
||||
|
||||
@ -57,8 +57,6 @@ class ImportLdi extends AbstractImportCsv
|
||||
$this->setLdiLocalOptionConfig();
|
||||
}
|
||||
|
||||
$importPluginProperties->setOptionsText(__('Options'));
|
||||
|
||||
// create the root group that will be the options field for
|
||||
// $importPluginProperties
|
||||
// this will be shown as "Format specific options"
|
||||
|
||||
@ -59,7 +59,6 @@ class ImportMediawiki extends ImportPlugin
|
||||
$importPluginProperties->setText(__('MediaWiki Table'));
|
||||
$importPluginProperties->setExtension('txt');
|
||||
$importPluginProperties->setMimeType('text/plain');
|
||||
$importPluginProperties->setOptionsText(__('Options'));
|
||||
|
||||
return $importPluginProperties;
|
||||
}
|
||||
|
||||
@ -57,7 +57,6 @@ class ImportOds extends ImportPlugin
|
||||
$importPluginProperties = new ImportPluginProperties();
|
||||
$importPluginProperties->setText('OpenDocument Spreadsheet');
|
||||
$importPluginProperties->setExtension('ods');
|
||||
$importPluginProperties->setOptionsText(__('Options'));
|
||||
|
||||
// create the root group that will be the options field for
|
||||
// $importPluginProperties
|
||||
|
||||
@ -73,7 +73,6 @@ class ImportShp extends ImportPlugin
|
||||
$importPluginProperties = new ImportPluginProperties();
|
||||
$importPluginProperties->setText(__('ESRI Shape File'));
|
||||
$importPluginProperties->setExtension('shp');
|
||||
$importPluginProperties->setOptionsText(__('Options'));
|
||||
|
||||
return $importPluginProperties;
|
||||
}
|
||||
|
||||
@ -40,7 +40,6 @@ class ImportSql extends ImportPlugin
|
||||
$importPluginProperties = new ImportPluginProperties();
|
||||
$importPluginProperties->setText('SQL');
|
||||
$importPluginProperties->setExtension('sql');
|
||||
$importPluginProperties->setOptionsText(__('Options'));
|
||||
|
||||
$compats = $this->dbi->getCompatibilities();
|
||||
if ($compats !== []) {
|
||||
|
||||
@ -48,7 +48,6 @@ class ImportXml extends ImportPlugin
|
||||
$importPluginProperties->setText(__('XML'));
|
||||
$importPluginProperties->setExtension('xml');
|
||||
$importPluginProperties->setMimeType('text/xml');
|
||||
$importPluginProperties->setOptionsText(__('Options'));
|
||||
|
||||
return $importPluginProperties;
|
||||
}
|
||||
|
||||
@ -49,7 +49,6 @@ class Import[Name] extends ImportPlugin
|
||||
$importPluginProperties = new PhpMyAdmin\Properties\Plugins\ImportPluginProperties();
|
||||
$importPluginProperties->setText('[name]'); // the name of your plug-in
|
||||
$importPluginProperties->setExtension('[ext]'); // extension this plug-in can handle
|
||||
$importPluginProperties->setOptionsText(__('Options'));
|
||||
|
||||
// create the root group that will be the options field for
|
||||
// $importPluginProperties
|
||||
|
||||
@ -21,7 +21,6 @@ abstract class PluginPropertyItem
|
||||
private string $text = '';
|
||||
private string $extension = '';
|
||||
private OptionsPropertyRootGroup|null $options = null;
|
||||
private string $optionsText = '';
|
||||
private string $mimeType = '';
|
||||
|
||||
public function getText(): string
|
||||
@ -54,16 +53,6 @@ abstract class PluginPropertyItem
|
||||
$this->options = $options;
|
||||
}
|
||||
|
||||
public function getOptionsText(): string
|
||||
{
|
||||
return $this->optionsText;
|
||||
}
|
||||
|
||||
public function setOptionsText(string $optionsText): void
|
||||
{
|
||||
$this->optionsText = $optionsText;
|
||||
}
|
||||
|
||||
public function getMimeType(): string
|
||||
{
|
||||
return $this->mimeType;
|
||||
|
||||
@ -56,11 +56,6 @@ final class ExportCodegenTest extends AbstractTestCase
|
||||
$properties->getMimeType(),
|
||||
);
|
||||
|
||||
self::assertSame(
|
||||
'Options',
|
||||
$properties->getOptionsText(),
|
||||
);
|
||||
|
||||
$options = $properties->getOptions();
|
||||
|
||||
self::assertInstanceOf(OptionsPropertyRootGroup::class, $options);
|
||||
|
||||
@ -67,11 +67,6 @@ final class ExportCsvTest extends AbstractTestCase
|
||||
$properties->getMimeType(),
|
||||
);
|
||||
|
||||
self::assertSame(
|
||||
'Options',
|
||||
$properties->getOptionsText(),
|
||||
);
|
||||
|
||||
$options = $properties->getOptions();
|
||||
|
||||
self::assertInstanceOf(OptionsPropertyRootGroup::class, $options);
|
||||
|
||||
@ -58,11 +58,6 @@ final class ExportExcelTest extends AbstractTestCase
|
||||
$properties->getMimeType(),
|
||||
);
|
||||
|
||||
self::assertSame(
|
||||
'Options',
|
||||
$properties->getOptionsText(),
|
||||
);
|
||||
|
||||
$options = $properties->getOptions();
|
||||
|
||||
self::assertInstanceOf(OptionsPropertyRootGroup::class, $options);
|
||||
|
||||
@ -79,11 +79,6 @@ final class ExportHtmlwordTest extends AbstractTestCase
|
||||
$properties->getMimeType(),
|
||||
);
|
||||
|
||||
self::assertSame(
|
||||
'Options',
|
||||
$properties->getOptionsText(),
|
||||
);
|
||||
|
||||
self::assertTrue(
|
||||
$properties->getForceFile(),
|
||||
);
|
||||
|
||||
@ -58,11 +58,6 @@ final class ExportJsonTest extends AbstractTestCase
|
||||
$properties->getMimeType(),
|
||||
);
|
||||
|
||||
self::assertSame(
|
||||
'Options',
|
||||
$properties->getOptionsText(),
|
||||
);
|
||||
|
||||
$options = $properties->getOptions();
|
||||
|
||||
self::assertInstanceOf(OptionsPropertyRootGroup::class, $options);
|
||||
|
||||
@ -87,11 +87,6 @@ final class ExportLatexTest extends AbstractTestCase
|
||||
$properties->getMimeType(),
|
||||
);
|
||||
|
||||
self::assertSame(
|
||||
'Options',
|
||||
$properties->getOptionsText(),
|
||||
);
|
||||
|
||||
$options = $properties->getOptions();
|
||||
|
||||
self::assertInstanceOf(OptionsPropertyRootGroup::class, $options);
|
||||
|
||||
@ -72,11 +72,6 @@ final class ExportMediawikiTest extends AbstractTestCase
|
||||
$properties->getMimeType(),
|
||||
);
|
||||
|
||||
self::assertSame(
|
||||
'Options',
|
||||
$properties->getOptionsText(),
|
||||
);
|
||||
|
||||
$options = $properties->getOptions();
|
||||
|
||||
self::assertInstanceOf(OptionsPropertyRootGroup::class, $options);
|
||||
|
||||
@ -77,11 +77,6 @@ final class ExportOdsTest extends AbstractTestCase
|
||||
$properties->getMimeType(),
|
||||
);
|
||||
|
||||
self::assertSame(
|
||||
'Options',
|
||||
$properties->getOptionsText(),
|
||||
);
|
||||
|
||||
self::assertTrue(
|
||||
$properties->getForceFile(),
|
||||
);
|
||||
|
||||
@ -97,11 +97,6 @@ final class ExportOdtTest extends AbstractTestCase
|
||||
$properties->getMimeType(),
|
||||
);
|
||||
|
||||
self::assertSame(
|
||||
'Options',
|
||||
$properties->getOptionsText(),
|
||||
);
|
||||
|
||||
self::assertTrue(
|
||||
$properties->getForceFile(),
|
||||
);
|
||||
|
||||
@ -64,11 +64,6 @@ final class ExportPdfTest extends AbstractTestCase
|
||||
$properties->getMimeType(),
|
||||
);
|
||||
|
||||
self::assertSame(
|
||||
'Options',
|
||||
$properties->getOptionsText(),
|
||||
);
|
||||
|
||||
self::assertTrue(
|
||||
$properties->getForceFile(),
|
||||
);
|
||||
|
||||
@ -64,11 +64,6 @@ final class ExportPhparrayTest extends AbstractTestCase
|
||||
$properties->getMimeType(),
|
||||
);
|
||||
|
||||
self::assertSame(
|
||||
'Options',
|
||||
$properties->getOptionsText(),
|
||||
);
|
||||
|
||||
$options = $properties->getOptions();
|
||||
|
||||
self::assertInstanceOf(OptionsPropertyRootGroup::class, $options);
|
||||
|
||||
@ -72,11 +72,6 @@ class ExportToonTest extends AbstractTestCase
|
||||
$properties->getMimeType(),
|
||||
);
|
||||
|
||||
self::assertSame(
|
||||
'Options',
|
||||
$properties->getOptionsText(),
|
||||
);
|
||||
|
||||
$options = $properties->getOptions();
|
||||
|
||||
self::assertInstanceOf(OptionsPropertyRootGroup::class, $options);
|
||||
|
||||
@ -71,10 +71,6 @@ final class ImportMediawikiTest extends AbstractTestCase
|
||||
$properties->getMimeType(),
|
||||
);
|
||||
self::assertNull($properties->getOptions());
|
||||
self::assertSame(
|
||||
__('Options'),
|
||||
$properties->getOptionsText(),
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@ -66,10 +66,6 @@ final class ImportOdsTest extends AbstractTestCase
|
||||
'ods',
|
||||
$properties->getExtension(),
|
||||
);
|
||||
self::assertSame(
|
||||
__('Options'),
|
||||
$properties->getOptionsText(),
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@ -94,10 +94,6 @@ final class ImportShpTest extends AbstractTestCase
|
||||
$properties->getExtension(),
|
||||
);
|
||||
self::assertNull($properties->getOptions());
|
||||
self::assertSame(
|
||||
__('Options'),
|
||||
$properties->getOptionsText(),
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@ -73,10 +73,6 @@ final class ImportXmlTest extends AbstractTestCase
|
||||
$properties->getMimeType(),
|
||||
);
|
||||
self::assertNull($properties->getOptions());
|
||||
self::assertSame(
|
||||
__('Options'),
|
||||
$properties->getOptionsText(),
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@ -23,21 +23,6 @@ class ImportPluginPropertiesTest extends AbstractTestCase
|
||||
$this->object = new ImportPluginProperties();
|
||||
}
|
||||
|
||||
/**
|
||||
* Test for
|
||||
* - PhpMyAdmin\Properties\Plugins\ImportPluginProperties::getOptionsText
|
||||
* - PhpMyAdmin\Properties\Plugins\ImportPluginProperties::setOptionsText
|
||||
*/
|
||||
public function testSetGetOptionsText(): void
|
||||
{
|
||||
$this->object->setOptionsText('options123');
|
||||
|
||||
self::assertSame(
|
||||
'options123',
|
||||
$this->object->getOptionsText(),
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Test for
|
||||
* - PhpMyAdmin\Properties\Plugins\ImportPluginProperties::setMimeType
|
||||
|
||||
Loading…
Reference in New Issue
Block a user