Skip to content

Commit 2d17d73

Browse files
committed
Release v4.6.0
1 parent fcf0099 commit 2d17d73

10 files changed

+106
-65
lines changed

app/Config/Cache.php

+2-12
Original file line numberDiff line numberDiff line change
@@ -34,18 +34,6 @@ class Cache extends BaseConfig
3434
*/
3535
public string $backupHandler = 'dummy';
3636

37-
/**
38-
* --------------------------------------------------------------------------
39-
* Cache Directory Path
40-
* --------------------------------------------------------------------------
41-
*
42-
* The path to where cache files should be stored, if using a file-based
43-
* system.
44-
*
45-
* @deprecated Use the driver-specific variant under $file
46-
*/
47-
public string $storePath = WRITEPATH . 'cache/';
48-
4937
/**
5038
* --------------------------------------------------------------------------
5139
* Key Prefix
@@ -86,6 +74,7 @@ class Cache extends BaseConfig
8674
* --------------------------------------------------------------------------
8775
* File settings
8876
* --------------------------------------------------------------------------
77+
*
8978
* Your file storage preferences can be specified below, if you are using
9079
* the File driver.
9180
*
@@ -100,6 +89,7 @@ class Cache extends BaseConfig
10089
* -------------------------------------------------------------------------
10190
* Memcached settings
10291
* -------------------------------------------------------------------------
92+
*
10393
* Your Memcached servers can be specified below, if you are using
10494
* the Memcached drivers.
10595
*

app/Config/Constants.php

-15
Original file line numberDiff line numberDiff line change
@@ -77,18 +77,3 @@
7777
defined('EXIT_DATABASE') || define('EXIT_DATABASE', 8); // database error
7878
defined('EXIT__AUTO_MIN') || define('EXIT__AUTO_MIN', 9); // lowest automatically-assigned error code
7979
defined('EXIT__AUTO_MAX') || define('EXIT__AUTO_MAX', 125); // highest automatically-assigned error code
80-
81-
/**
82-
* @deprecated Use \CodeIgniter\Events\Events::PRIORITY_LOW instead.
83-
*/
84-
define('EVENT_PRIORITY_LOW', 200);
85-
86-
/**
87-
* @deprecated Use \CodeIgniter\Events\Events::PRIORITY_NORMAL instead.
88-
*/
89-
define('EVENT_PRIORITY_NORMAL', 100);
90-
91-
/**
92-
* @deprecated Use \CodeIgniter\Events\Events::PRIORITY_HIGH instead.
93-
*/
94-
define('EVENT_PRIORITY_HIGH', 10);

app/Config/Database.php

+2
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ class Database extends Config
4343
'failover' => [],
4444
'port' => 3306,
4545
'numberNative' => false,
46+
'foundRows' => false,
4647
'dateFormat' => [
4748
'date' => 'Y-m-d',
4849
'datetime' => 'Y-m-d H:i:s',
@@ -64,6 +65,7 @@ class Database extends Config
6465
// 'failover' => [],
6566
// 'foreignKeys' => true,
6667
// 'busyTimeout' => 1000,
68+
// 'synchronous' => null,
6769
// 'dateFormat' => [
6870
// 'date' => 'Y-m-d',
6971
// 'datetime' => 'Y-m-d H:i:s',

app/Config/Feature.php

+10-2
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@
1010
class Feature extends BaseConfig
1111
{
1212
/**
13-
* Use improved new auto routing instead of the default legacy version.
13+
* Use improved new auto routing instead of the legacy version.
1414
*/
15-
public bool $autoRoutesImproved = false;
15+
public bool $autoRoutesImproved = true;
1616

1717
/**
1818
* Use filter execution order in 4.4 or before.
@@ -26,4 +26,12 @@ class Feature extends BaseConfig
2626
* If false, `limit(0)` returns no records. (the behavior of 3.1.9 or later in version 3.x.)
2727
*/
2828
public bool $limitZeroAsAll = true;
29+
30+
/**
31+
* Use strict location negotiation.
32+
*
33+
* By default, the locale is selected based on a loose comparison of the language code (ISO 639-1)
34+
* Enabling strict comparison will also consider the region code (ISO 3166-1 alpha-2).
35+
*/
36+
public bool $strictLocaleNegotiation = false;
2937
}

app/Config/Format.php

-13
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
namespace Config;
44

55
use CodeIgniter\Config\BaseConfig;
6-
use CodeIgniter\Format\FormatterInterface;
76
use CodeIgniter\Format\JSONFormatter;
87
use CodeIgniter\Format\XMLFormatter;
98

@@ -62,16 +61,4 @@ class Format extends BaseConfig
6261
'application/xml' => 0,
6362
'text/xml' => 0,
6463
];
65-
66-
/**
67-
* A Factory method to return the appropriate formatter for the given mime type.
68-
*
69-
* @return FormatterInterface
70-
*
71-
* @deprecated This is an alias of `\CodeIgniter\Format\Format::getFormatter`. Use that instead.
72-
*/
73-
public function getFormatter(string $mime)
74-
{
75-
return service('format')->getFormatter($mime);
76-
}
7764
}

app/Config/Kint.php

-2
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
namespace Config;
44

55
use Kint\Parser\ConstructablePluginInterface;
6-
use Kint\Renderer\AbstractRenderer;
76
use Kint\Renderer\Rich\TabPluginInterface;
87
use Kint\Renderer\Rich\ValuePluginInterface;
98

@@ -41,7 +40,6 @@ class Kint
4140
*/
4241
public string $richTheme = 'aante-light.css';
4342
public bool $richFolder = false;
44-
public int $richSort = AbstractRenderer::SORT_FULL;
4543

4644
/**
4745
* @var array<string, class-string<ValuePluginInterface>>|null

app/Config/Routing.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -136,5 +136,5 @@ class Routing extends BaseRouting
136136
*
137137
* Default: false
138138
*/
139-
public bool $translateUriToCamelCase = false;
139+
public bool $translateUriToCamelCase = true;
140140
}

app/Config/Security.php

-17
Original file line numberDiff line numberDiff line change
@@ -83,21 +83,4 @@ class Security extends BaseConfig
8383
* @see https://codeigniter4.github.io/userguide/libraries/security.html#redirection-on-failure
8484
*/
8585
public bool $redirect = (ENVIRONMENT === 'production');
86-
87-
/**
88-
* --------------------------------------------------------------------------
89-
* CSRF SameSite
90-
* --------------------------------------------------------------------------
91-
*
92-
* Setting for CSRF SameSite cookie token.
93-
*
94-
* Allowed values are: None - Lax - Strict - ''.
95-
*
96-
* Defaults to `Lax` as recommended in this link:
97-
*
98-
* @see https://portswigger.net/web-security/csrf/samesite-cookies
99-
*
100-
* @deprecated `Config\Cookie` $samesite property is used.
101-
*/
102-
public string $samesite = 'Lax';
10386
}

app/Views/errors/html/debug.css

+7-3
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ p.lead {
4141
.header {
4242
background: var(--light-bg-color);
4343
color: var(--dark-text-color);
44+
margin-top: 2.17rem;
4445
}
4546
.header .container {
4647
padding: 1rem;
@@ -65,10 +66,13 @@ p.lead {
6566
}
6667

6768
.environment {
68-
background: var(--dark-bg-color);
69-
color: var(--light-text-color);
69+
background: var(--brand-primary-color);
70+
color: var(--main-bg-color);
7071
text-align: center;
71-
padding: 0.2rem;
72+
padding: calc(4px + 0.2083vw);
73+
width: 100%;
74+
margin-top: -2.14rem;
75+
position: fixed;
7276
}
7377

7478
.source {

app/Views/errors/html/error_400.php

+84
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,84 @@
1+
<!DOCTYPE html>
2+
<html lang="en">
3+
<head>
4+
<meta charset="utf-8">
5+
<title><?= lang('Errors.badRequest') ?></title>
6+
7+
<style>
8+
div.logo {
9+
height: 200px;
10+
width: 155px;
11+
display: inline-block;
12+
opacity: 0.08;
13+
position: absolute;
14+
top: 2rem;
15+
left: 50%;
16+
margin-left: -73px;
17+
}
18+
body {
19+
height: 100%;
20+
background: #fafafa;
21+
font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
22+
color: #777;
23+
font-weight: 300;
24+
}
25+
h1 {
26+
font-weight: lighter;
27+
letter-spacing: normal;
28+
font-size: 3rem;
29+
margin-top: 0;
30+
margin-bottom: 0;
31+
color: #222;
32+
}
33+
.wrap {
34+
max-width: 1024px;
35+
margin: 5rem auto;
36+
padding: 2rem;
37+
background: #fff;
38+
text-align: center;
39+
border: 1px solid #efefef;
40+
border-radius: 0.5rem;
41+
position: relative;
42+
}
43+
pre {
44+
white-space: normal;
45+
margin-top: 1.5rem;
46+
}
47+
code {
48+
background: #fafafa;
49+
border: 1px solid #efefef;
50+
padding: 0.5rem 1rem;
51+
border-radius: 5px;
52+
display: block;
53+
}
54+
p {
55+
margin-top: 1.5rem;
56+
}
57+
.footer {
58+
margin-top: 2rem;
59+
border-top: 1px solid #efefef;
60+
padding: 1em 2em 0 2em;
61+
font-size: 85%;
62+
color: #999;
63+
}
64+
a:active,
65+
a:link,
66+
a:visited {
67+
color: #dd4814;
68+
}
69+
</style>
70+
</head>
71+
<body>
72+
<div class="wrap">
73+
<h1>400</h1>
74+
75+
<p>
76+
<?php if (ENVIRONMENT !== 'production') : ?>
77+
<?= nl2br(esc($message)) ?>
78+
<?php else : ?>
79+
<?= lang('Errors.sorryBadRequest') ?>
80+
<?php endif; ?>
81+
</p>
82+
</div>
83+
</body>
84+
</html>

0 commit comments

Comments
 (0)