mirror of
https://github.com/codeigniter4/CodeIgniter4.git
synced 2025-02-20 11:44:28 +08:00
Merge pull request #1181 from samsonasik/string-param-dotenv
use string type hint in $file parameter in DotEnv::__construct()
This commit is contained in:
commit
e9a1d8ae4d
@ -57,13 +57,8 @@ class DotEnv
|
||||
* @param string $path
|
||||
* @param string $file
|
||||
*/
|
||||
public function __construct(string $path, $file = '.env')
|
||||
public function __construct(string $path, string $file = '.env')
|
||||
{
|
||||
if ( ! is_string($file))
|
||||
{
|
||||
$file = '.env';
|
||||
}
|
||||
|
||||
$this->path = rtrim($path, DIRECTORY_SEPARATOR) . DIRECTORY_SEPARATOR . $file;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user