diff --git a/inc/class-local-stream-wrapper.php b/inc/class-local-stream-wrapper.php index c134f513..0a3fbf25 100644 --- a/inc/class-local-stream-wrapper.php +++ b/inc/class-local-stream-wrapper.php @@ -143,7 +143,7 @@ protected function getLocalPath( $uri = null ) { $uri = $this->uri; } $path = $this->getDirectoryPath() . '/' . $this->getTarget( $uri ); - $realpath = $path; + $realpath = str_replace( '/', DIRECTORY_SEPARATOR, $path ); // ensure check against realpath passes on Windows machines $directory = realpath( $this->getDirectoryPath() ); diff --git a/inc/class-plugin.php b/inc/class-plugin.php index 2a27be64..fda496b2 100644 --- a/inc/class-plugin.php +++ b/inc/class-plugin.php @@ -157,7 +157,7 @@ public function register_stream_wrapper() { /** * Get the s3:// path for the bucket. */ - public function get_s3_path() { + public function get_s3_path() : string { return 's3://' . $this->bucket; }