Skip to content

Commit cb650d2

Browse files
committed
Merge branch 'QA_5_1'
Signed-off-by: Maurício Meneghini Fauth <mauricio@fauth.dev>
2 parents 283a720 + 679eca2 commit cb650d2

7 files changed

Lines changed: 42 additions & 34 deletions

File tree

‎composer.json‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@
100100
"roave/security-advisories": "dev-latest",
101101
"code-lts/u2f-php-server": "^1.2",
102102
"symfony/console": "^5.2.3",
103-
"tecnickcom/tcpdf": "^6.4.2",
103+
"tecnickcom/tcpdf": "^6.4.3",
104104
"vimeo/psalm": "^4.15.0"
105105
},
106106
"extra": {

‎libraries/classes/Pdf.php‎

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -35,14 +35,13 @@ class Pdf extends TCPDF
3535
/**
3636
* Constructs PDF and configures standard parameters.
3737
*
38-
* @param string $orientation page orientation
39-
* @param string $unit unit
40-
* @param string $format the format used for pages
41-
* @param bool $unicode true means that the input text is unicode
42-
* @param string $encoding charset encoding; default is UTF-8.
43-
* @param bool $diskcache if true reduce the RAM memory usage by caching
44-
* temporary data on filesystem (slower).
45-
* @param bool $pdfa If TRUE set the document to PDF/A mode.
38+
* @param string $orientation page orientation
39+
* @param string $unit unit
40+
* @param string $format the format used for pages
41+
* @param bool $unicode true means that the input text is unicode
42+
* @param string $encoding charset encoding; default is UTF-8.
43+
* @param bool $diskcache DEPRECATED TCPDF FEATURE
44+
* @param false|int $pdfa If not false, set the document to PDF/A mode and the good version (1 or 3)
4645
*
4746
* @throws Exception
4847
*/

‎libraries/classes/Plugins/Export/Helpers/Pdf.php‎

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -97,14 +97,13 @@ class Pdf extends PdfLib
9797
/**
9898
* Constructs PDF and configures standard parameters.
9999
*
100-
* @param string $orientation page orientation
101-
* @param string $unit unit
102-
* @param string $format the format used for pages
103-
* @param bool $unicode true means that the input text is unicode
104-
* @param string $encoding charset encoding; default is UTF-8.
105-
* @param bool $diskcache if true reduce the RAM memory usage by caching
106-
* temporary data on filesystem (slower).
107-
* @param bool $pdfa If TRUE set the document to PDF/A mode.
100+
* @param string $orientation page orientation
101+
* @param string $unit unit
102+
* @param string $format the format used for pages
103+
* @param bool $unicode true means that the input text is unicode
104+
* @param string $encoding charset encoding; default is UTF-8.
105+
* @param bool $diskcache DEPRECATED TCPDF FEATURE
106+
* @param false|int $pdfa If not false, set the document to PDF/A mode and the good version (1 or 3)
108107
*/
109108
public function __construct(
110109
$orientation = 'P',

‎phpstan-baseline.neon‎

Lines changed: 20 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -395,6 +395,11 @@ parameters:
395395
count: 1
396396
path: libraries/classes/Config/Form.php
397397

398+
-
399+
message: "#^Unreachable statement \\- code above always terminates\\.$#"
400+
count: 2
401+
path: libraries/classes/Config/Form.php
402+
398403
-
399404
message: "#^Argument of an invalid type mixed supplied for foreach, only iterables are supported\\.$#"
400405
count: 1
@@ -6040,16 +6045,6 @@ parameters:
60406045
count: 1
60416046
path: libraries/classes/Partitioning/TablePartitionDefinition.php
60426047

6043-
-
6044-
message: "#^Parameter \\#1 \\$font of method TCPDF\\:\\:setFooterFont\\(\\) expects array\\<int, string\\>, array\\<int, int\\|string\\> given\\.$#"
6045-
count: 1
6046-
path: libraries/classes/Pdf.php
6047-
6048-
-
6049-
message: "#^Parameter \\#7 \\$pdfa of method TCPDF\\:\\:__construct\\(\\) expects int, bool given\\.$#"
6050-
count: 1
6051-
path: libraries/classes/Pdf.php
6052-
60536048
-
60546049
message: "#^Property PhpMyAdmin\\\\Pdf\\:\\:\\$alias type has no value type specified in iterable type array\\.$#"
60556050
count: 1
@@ -8940,6 +8935,16 @@ parameters:
89408935
count: 1
89418936
path: libraries/classes/Theme.php
89428937

8938+
-
8939+
message: "#^Unreachable statement \\- code above always terminates\\.$#"
8940+
count: 1
8941+
path: libraries/classes/Theme.php
8942+
8943+
-
8944+
message: "#^If condition is always true\\.$#"
8945+
count: 1
8946+
path: libraries/classes/ThemeManager.php
8947+
89438948
-
89448949
message: "#^Method PhpMyAdmin\\\\ThemeManager\\:\\:getThemesArray\\(\\) return type has no value type specified in iterable type array\\.$#"
89458950
count: 1
@@ -8955,6 +8960,11 @@ parameters:
89558960
count: 1
89568961
path: libraries/classes/ThemeManager.php
89578962

8963+
-
8964+
message: "#^Unreachable statement \\- code above always terminates\\.$#"
8965+
count: 2
8966+
path: libraries/classes/ThemeManager.php
8967+
89588968
-
89598969
message: "#^Cannot access property \\$table on PhpMyAdmin\\\\SqlParser\\\\Components\\\\Expression\\|string\\.$#"
89608970
count: 1

‎psalm-baseline.xml‎

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9289,10 +9289,6 @@
92899289
</MixedOperand>
92909290
</file>
92919291
<file src="libraries/classes/Pdf.php">
9292-
<InvalidScalarArgument occurrences="2">
9293-
<code>$pdfa</code>
9294-
<code>[self::PMA_PDF_FONT, '', 14]</code>
9295-
</InvalidScalarArgument>
92969292
<MixedArgument occurrences="4">
92979293
<code>$pdfData</code>
92989294
<code>$this-&gt;CurrentFont</code>

‎scripts/create-release.sh‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -214,6 +214,7 @@ cleanup_composer_vendors() {
214214
vendor/google/recaptcha/examples/ \
215215
vendor/google/recaptcha/tests/
216216
rm -rf \
217+
vendor/google/recaptcha/ARCHITECTURE.md \
217218
vendor/google/recaptcha/CONTRIBUTING.md \
218219
vendor/phpmyadmin/motranslator/CODE_OF_CONDUCT.md \
219220
vendor/phpmyadmin/motranslator/CONTRIBUTING.md \

‎scripts/lang-cleanup.sh‎

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,17 +32,20 @@ for type in "$@" ; do
3232
english)
3333
rm -rf po
3434
rm -rf locale
35+
rm -rf vendor/phpmyadmin/sql-parser/locale
3536
exit 0
3637
;;
3738
*)
38-
match="$match -and -not -name $type.po -and -not -path locale/$type/LC_MESSAGES/phpmyadmin.mo"
39+
match="$match -and -not -name $type.po -and -not -path locale/$type/LC_MESSAGES/phpmyadmin.mo -and -not -path vendor/phpmyadmin/sql-parser/locale/$type/LC_MESSAGES/sqlparser.mo"
3940
;;
4041
esac
4142
done
4243

43-
# Delete unvanted languages
44-
find po locale -type f $match -print0 | xargs -0r rm
44+
# Delete unwanted languages
45+
find po locale vendor/phpmyadmin/sql-parser/locale -type f $match -print0 | xargs -0r rm
4546

4647
# Delete empty directories
4748
rmdir --ignore-fail-on-non-empty locale/*/*
4849
rmdir --ignore-fail-on-non-empty locale/*
50+
rmdir --ignore-fail-on-non-empty vendor/phpmyadmin/sql-parser/locale/*/*
51+
rmdir --ignore-fail-on-non-empty vendor/phpmyadmin/sql-parser/locale/*

0 commit comments

Comments
 (0)