5486 Commits

Author SHA1 Message Date
Michal Sniatala
c430f34720
fix: set headers for CORS (#9437)
Some checks failed
PHPUnit / DatabaseLive (MySQLi, 5.7, 8.1) (push) Has been cancelled
PHPUnit / DatabaseLive (MySQLi, 8.0, 8.1) (push) Has been cancelled
PHPUnit / DatabaseLive (MySQLi, 8.0, 8.2) (push) Has been cancelled
PHPUnit / DatabaseLive (MySQLi, 8.0, 8.3) (push) Has been cancelled
PHPUnit / DatabaseLive (MySQLi, 8.0, 8.4) (push) Has been cancelled
PHPUnit / DatabaseLive (OCI8, 8.0, 8.1) (push) Has been cancelled
PHPUnit / DatabaseLive (OCI8, 8.0, 8.2) (push) Has been cancelled
PHPUnit / DatabaseLive (OCI8, 8.0, 8.3) (push) Has been cancelled
PHPUnit / DatabaseLive (OCI8, 8.0, 8.4) (push) Has been cancelled
PHPUnit / DatabaseLive (Postgre, 8.0, 8.1) (push) Has been cancelled
PHPUnit / DatabaseLive (Postgre, 8.0, 8.2) (push) Has been cancelled
PHPUnit / DatabaseLive (Postgre, 8.0, 8.3) (push) Has been cancelled
PHPUnit / DatabaseLive (Postgre, 8.0, 8.4) (push) Has been cancelled
PHPUnit / DatabaseLive (SQLSRV, 8.0, 8.1) (push) Has been cancelled
PHPUnit / DatabaseLive (SQLSRV, 8.0, 8.2) (push) Has been cancelled
PHPUnit / DatabaseLive (SQLSRV, 8.0, 8.3) (push) Has been cancelled
PHPUnit / DatabaseLive (SQLSRV, 8.0, 8.4) (push) Has been cancelled
PHPUnit / DatabaseLive (SQLite3, 8.0, 8.1) (push) Has been cancelled
PHPUnit / DatabaseLive (SQLite3, 8.0, 8.2) (push) Has been cancelled
PHPUnit / DatabaseLive (SQLite3, 8.0, 8.3) (push) Has been cancelled
PHPUnit / DatabaseLive (SQLite3, 8.0, 8.4) (push) Has been cancelled
PHPUnit / SeparateProcess (8.1) (push) Has been cancelled
PHPUnit / SeparateProcess (8.2) (push) Has been cancelled
PHPUnit / SeparateProcess (8.3) (push) Has been cancelled
PHPUnit / SeparateProcess (8.4) (push) Has been cancelled
PHPUnit / CacheLive (8.1) (push) Has been cancelled
PHPUnit / CacheLive (8.2) (push) Has been cancelled
PHPUnit / CacheLive (8.3) (push) Has been cancelled
PHPUnit / CacheLive (8.4) (push) Has been cancelled
PHPUnit / Upload coverage results to Coveralls (push) Has been cancelled
* fix: set everything in the before filter for CORS

* fix append vary header

* cors: apply response headers in the after filter only if they are not already set

* cs fix
2025-02-08 19:43:28 +01:00
Abdul Malik Ikhsan
3eae99070b
refactor: use assertNotInstanceOf over assertNull on nullable object return and flip actual/expect on constant check 2025-02-04 09:00:10 +07:00
Thomas Nguyen
909e9b0a1a
fix(CURLRequest): multiple header sections after redirects (#9426)
Some checks failed
PHPUnit / DatabaseLive (MySQLi, 5.7, 8.1) (push) Has been cancelled
PHPUnit / DatabaseLive (MySQLi, 8.0, 8.1) (push) Has been cancelled
PHPUnit / DatabaseLive (MySQLi, 8.0, 8.2) (push) Has been cancelled
PHPUnit / DatabaseLive (MySQLi, 8.0, 8.3) (push) Has been cancelled
PHPUnit / DatabaseLive (MySQLi, 8.0, 8.4) (push) Has been cancelled
PHPUnit / DatabaseLive (OCI8, 8.0, 8.1) (push) Has been cancelled
PHPUnit / DatabaseLive (OCI8, 8.0, 8.2) (push) Has been cancelled
PHPUnit / DatabaseLive (OCI8, 8.0, 8.3) (push) Has been cancelled
PHPUnit / DatabaseLive (OCI8, 8.0, 8.4) (push) Has been cancelled
PHPUnit / DatabaseLive (Postgre, 8.0, 8.1) (push) Has been cancelled
PHPUnit / DatabaseLive (Postgre, 8.0, 8.2) (push) Has been cancelled
PHPUnit / DatabaseLive (Postgre, 8.0, 8.3) (push) Has been cancelled
PHPUnit / DatabaseLive (Postgre, 8.0, 8.4) (push) Has been cancelled
PHPUnit / DatabaseLive (SQLSRV, 8.0, 8.1) (push) Has been cancelled
PHPUnit / DatabaseLive (SQLSRV, 8.0, 8.2) (push) Has been cancelled
PHPUnit / DatabaseLive (SQLSRV, 8.0, 8.3) (push) Has been cancelled
PHPUnit / DatabaseLive (SQLSRV, 8.0, 8.4) (push) Has been cancelled
PHPUnit / DatabaseLive (SQLite3, 8.0, 8.1) (push) Has been cancelled
PHPUnit / DatabaseLive (SQLite3, 8.0, 8.2) (push) Has been cancelled
PHPUnit / DatabaseLive (SQLite3, 8.0, 8.3) (push) Has been cancelled
PHPUnit / DatabaseLive (SQLite3, 8.0, 8.4) (push) Has been cancelled
PHPUnit / SeparateProcess (8.1) (push) Has been cancelled
PHPUnit / SeparateProcess (8.2) (push) Has been cancelled
PHPUnit / SeparateProcess (8.3) (push) Has been cancelled
PHPUnit / SeparateProcess (8.4) (push) Has been cancelled
PHPUnit / CacheLive (8.1) (push) Has been cancelled
PHPUnit / CacheLive (8.2) (push) Has been cancelled
PHPUnit / CacheLive (8.3) (push) Has been cancelled
PHPUnit / CacheLive (8.4) (push) Has been cancelled
PHPUnit / Upload coverage results to Coveralls (push) Has been cancelled
* fix: strip out multiple header sections for redirect

* test: add test for stripping out multiple redirect header sections

* docs: changelog for fixing returning multiple header sections after redirects

* Added a non-standard http redirect code test

* apply cs-fix for test

* Moved redirect header loop to a separate function

* Updated changelog to be clearer
2025-01-23 09:28:25 +08:00
John Paul E. Balandan, CPA
6414090ebe
Merge branch 'develop' into 4.6 2025-01-19 22:21:16 +08:00
Ngô Quốc Đạt
97a6d66640
fix: ensure csrf token is string (#9365)
* fix: ensure csrf token is string

* fix: ensure csrf token is string

* handle request php://input

* handle request php://input

* wip

* wip

* wip

* wip

Co-authored-by: Michal Sniatala <michal@sniatala.pl>

* wip

Co-authored-by: Michal Sniatala <michal@sniatala.pl>

* Update user_guide_src/source/changelogs/v4.5.8.rst

* Use data providers

---------

Co-authored-by: Michal Sniatala <michal@sniatala.pl>
Co-authored-by: John Paul E. Balandan, CPA <paulbalandan@gmail.com>
2025-01-18 22:33:37 +08:00
Michal Sniatala
5f8aa24280
Merge commit from fork
Co-authored-by: neznaika0 <ozornick.ks@gmail.com>
Co-authored-by: John Paul E. Balandan, CPA <paulbalandan@gmail.com>
2025-01-18 11:54:38 +01:00
John Paul E. Balandan, CPA
80719d473b
Merge branch 'develop' into 4.6 2025-01-18 01:42:58 +08:00
John Paul E. Balandan, CPA
119330c56f
refactor: Use strtolower with str_contains/str_**_with as replacement for stripos (#9414)
* Use `modernize_stripos` option

* Fix impossible conditional in test
2025-01-17 22:51:06 +08:00
neznaika0
17d6adeee4
refactor: Remove deprecation related to cookies (#9406)
* refactor: Remove deprecated `Config\Security::$samesite`

* refactor: Remove deprecated methods in `CookieStore`

* docs: Update changelog

* refactor: Update phpstan baseline

* docs: Update userguide

* refactor: Remove deprecated  `Cookie::withNeverExpiring()`

* docs: Update changelog, userguide
2025-01-14 13:50:28 +08:00
neznaika0
d47a25850c
chore: Fix phpunit deprecations (#9402)
* refactor: Remove unknown option

* refactor: Remove deprecated `CoversTrait`
2025-01-14 11:42:27 +08:00
neznaika0
c6bb6e9552
refactor: Remove deprecated Cache::$storePath 2025-01-13 07:54:39 +03:00
neznaika0
a3704a1df4
refactor: Fix phpstan codeigniter.frameworkExceptionInstance (#9389) 2025-01-13 12:49:37 +08:00
neznaika0
4c16324780
refactor: Remove deprecated EVENT_PRIORITY_* (#9401)
* refactor: Remove deprecated `EVENT_PRIORITY_*`

* docs: Update changelog, userguide
2025-01-13 11:34:13 +08:00
John Paul E. Balandan, CPA
797d37751a
Merge branch 'develop' into 4.6 2025-01-13 11:15:24 +08:00
John Paul E. Balandan, CPA
c3ac0f9483
chore: add more trailing commas in more places (#9395)
* Apply to parameters

* Apply to array destructuring

* Apply to match

* Apply for arguments
2025-01-13 11:03:02 +08:00
neznaika0
155f1c14de
refactor: Fix phpstan codeigniter.configArgumentInstanceof (#9390) 2025-01-13 10:52:54 +08:00
neznaika0
f67bc687d5
refactor: Remove deprecated RedirectException (#9399)
* refacror: Remove CodeIgniter\Router\Exceptions\RedirectException

* docs: Update changelog, userguide
2025-01-12 03:12:59 +08:00
Denny Septian Panggabean
468e84b89e
feat: additional opcache setting in check php.ini (#9032)
* feat: additional opcache setting in check PHP.ini

* fix: PHPUnit fails

* fix: remark memory_consumption

* fix: adjust remark

* fix: add argument for opcache only

* tests: add argument for opcache only

* fix: typo

* fix: errors on GA

* Update system/Commands/Utilities/PhpIniCheck.php

Co-authored-by: kenjis <kenji.uui@gmail.com>

* Update system/Security/CheckPhpIni.php

Co-authored-by: kenjis <kenji.uui@gmail.com>

* fix: typo

* refactor: remark certain provisions

* tests: fix remark save_comments

* fix: typo

---------

Co-authored-by: kenjis <kenji.uui@gmail.com>
2025-01-11 17:30:46 +01:00
neznaika0
e3a139db12
refactor: Fix phpstan method.impossibleType (#9384)
* refactor: Fix phpstan method.impossibleType

* refactor: Fix phpstan method.notFound for EventsTest

* fix: Run fixer
2025-01-10 21:12:42 +08:00
neznaika0
131c5ebeee
refactor: Fix phpstan method.unused (#9388) 2025-01-10 21:11:41 +08:00
Abdul Malik Ikhsan
0ecfb1eb56
refactor: using property promotion on ResponseTraitTest 2025-01-10 19:46:58 +07:00
neznaika0
47a6f8af18
refactor: Rework exit codes, skip dots 2025-01-10 10:17:38 +03:00
neznaika0
9c92041159
fix: Update tests to be readable 2025-01-10 08:33:17 +03:00
neznaika0
d23c879cc2
Remove array helper intersectKeyRecursive 2025-01-10 08:33:16 +03:00
neznaika0
5448d7a915
fix: Delete debug info 2025-01-10 08:33:16 +03:00
neznaika0
49d7a8730d
feat: Add array helper intersectKeyRecursive 2025-01-10 08:33:15 +03:00
neznaika0
872434a6ff
test: Add tests for lang:sync command 2025-01-10 08:33:15 +03:00
neznaika0
72b7f8a0dd
refactor: Fix phpstan return.type (#9375)
* refactor: Fix phpstan return.type

* refactor: Fix phpstan return.type
2025-01-09 00:09:58 +08:00
neznaika0
3eb8a09514
refactor: Fix phpstan expr.resultUnused (#9385) 2025-01-09 00:04:11 +08:00
John Paul E. Balandan, CPA
e475fd8fa4
Merge branch 'develop' into 4.6 2025-01-08 02:49:47 +08:00
Murilo Henrique Pucci
d9aca420f4
feat: add page start end total to PagerRenderer (#9371)
* Add some methods to the page renderer to make easier to
get the first item, the last item and the total of items.

* Add type hint to the new per page variable on the page renderer.

* Create more tests for the page start and end, and improve the comment of the variables from the PagerRenderer class.

* Add a documentation and also improve some comments.

* Use version added instead of warning on the documentation

* Add changelog.

* Fix CR issues.

* Add null as the default value for perPageStart and End
2025-01-08 02:46:05 +08:00
neznaika0
c79d3a9758
fix: Add support for multibyte strings (#9372)
* fix: Truncate multibyte namespaces in command

* fix: Add support multibyte to `View->excerpt()`

* fix: Add support multibyte to `excerpt()` helper

* docs: Update changelog

* fix: Improve readability `excerpt()`

* refactor: Rework `character_limiter()`

* refactor: Rework test `TextHelper`

* docs: Move to 4.6 branch
2025-01-08 02:37:23 +08:00
neznaika0
cd27b6aa7f
refactor: Fix phpstan class.notFound (#9376) 2025-01-06 21:22:55 +08:00
neznaika0
08540f7688
refactor: Fix phpstan function.inner (#9377) 2025-01-06 21:22:36 +08:00
michalsn
c3bfac5261
Merge remote-tracking branch 'upstream/develop' into 4.6
# Conflicts:
#	composer.json
#	utils/phpstan-baseline/missingType.iterableValue.neon
2025-01-06 09:51:34 +01:00
neznaika0
f61361d4db
refactor: Fix phpstan generator.returnType 2025-01-05 20:40:55 +03:00
neznaika0
cc96fe3639
feat: Strict locale negotiation (#9360)
* feat: Add parameter for locale comparison

* feat: Update language negotiator

* tests: Update `NegotiateTest`

* docs: Update userguide

* fix: Rename feature option

* feat: Add `getBestLocaleMatch()`

* tests: Update `Negotiate` tests

* docs: Update docs

* fix: Rename feature option to back

* docs: Update the description for Negotiation

* fix: Update with the renamed option

* fix: Delete checking *.*

* fix: Move code to  file
2025-01-05 12:40:35 +08:00
neznaika0
91e788a79c
refactor: phpstan function.notFound (#9366) 2025-01-04 17:54:04 +08:00
Michal Sniatala
046967af08
fix: gather affected rows after query call failed (#9363)
* fix: gather affected rows after query call failed

* update user guide

* fix test

* fix test

* fix failing tests for mysqli - enable strict mode

* cs fix
2025-01-03 06:57:55 +01:00
John Paul E. Balandan, CPA
eec3739823
Merge remote-tracking branch 'upstream/develop' into 4.6 2024-12-31 20:22:12 +08:00
John Paul E. Balandan, CPA
d7ce2ba7d3
fix: Forge::dropColumn() always returns false on SQLite3 driver (#9351) 2024-12-31 18:41:07 +08:00
Abdul Malik Ikhsan
f551dbd0ad
fix: handle namespaced helper found on Common helper 2024-12-30 21:11:28 +07:00
John Paul E. Balandan, CPA
c7548a3771
Merge branch 'develop' into 4.6 2024-12-29 00:21:53 +08:00
Abdul Malik Ikhsan
a2ec5054d7
refactor: enable AddArrowFunctionReturnTypeRector 2024-12-28 23:00:15 +07:00
neznaika0
8cff0995de
refactor: fix phpstan only boolean allowed (#9302)
* refactor: Fix `phpstan` boolean errors

* fix: Check predis response

* refactor: Improve comparison with an empty string

* dev: Update phpstan-baseline

* fix: Revert comparison with null
2024-12-28 20:21:06 +08:00
John Paul E. Balandan, CPA
19ad2b99cc
refactor: fix used void return type (#9341) 2024-12-28 14:31:01 +08:00
John Paul E. Balandan, CPA
2114577483
refactor: fix warning on new static usage 2024-12-27 23:24:05 +08:00
Michal Sniatala
22b8e9e9d9
fix: prioritize headers set by the Response class (#9235)
* fix: prioritize headers set by the Response class

* cs fix

* add a note to the user guide

* docs: add an example to the header changes

* Update user_guide_src/source/changelogs/v4.6.0.rst

Co-authored-by: John Paul E. Balandan, CPA <paulbalandan@gmail.com>

---------

Co-authored-by: John Paul E. Balandan, CPA <paulbalandan@gmail.com>
2024-12-27 13:11:59 +01:00
Michal Sniatala
6cbbf601b0
fix: handling binary data for prepared statement (#9337)
* fix prepare statement sqlite

* fix prepare statement postgre

* fix prepare statement sqlsrv

* fix prepare statement oci8

* tests

* abstract isBinary() method

* fix prepare statement mysqli

* fix prepare statement oci8

* sqlsrv blob support

* fix tests

* add changelog

* fix rector

* make sqlsrv happy

* make oci8 happy - hopefully

* add a note about options for prepared statement

* ignore PreparedQueryTest.php file

* apply code suggestion for oci8
2024-12-27 08:14:06 +01:00
Abdul Malik Ikhsan
345e1c3b9c
refactor: enable code quality level 34 for rector (#9311)
* refactor: enable code quality level 34 for rector

* refactor: run cs fix

* refactor: fix phpstan and regenerate baseline

* refactor: cs fix

* refactor: Cors: before never returns string

* refactor: return EXIT_ERROR on check verify command

* refactor: returns null on DebugToolbar and HoneyPot
2024-12-21 19:40:05 +08:00