Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

Adding an is_file check to the path to prevent remote file include issue... #11

Merged
merged 1 commit into from

2 participants

@enygma

...s (Issue #10)

@vlucas
Owner

Thanks for closing out this issue. :+1:

@vlucas vlucas merged commit f16b111 into vlucas:master
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Jan 24, 2014
  1. Adding an is_file check to the path to prevent remote file include is…

    Chris Cornutt authored
    …sues (Issue #10)
This page is out of date. Refresh to see the latest.
Showing with 1 addition and 1 deletion.
  1. +1 −1  src/Dotenv.php
View
2  src/Dotenv.php
@@ -16,7 +16,7 @@ public static function load($path, $file = '.env')
}
$filePath = rtrim($path, '/') . '/' . $file;
- if(!file_exists($filePath)) {
+ if(!file_exists($filePath) || !is_file($filePath)) {
throw new \InvalidArgumentException("Dotenv: Environment file .env not found. Create file with your environment settings at " . $filePath);
}
Something went wrong with that request. Please try again.