From 72ca081bd44ae4fa905e3c0c48a2b2a76c1a9b3d Mon Sep 17 00:00:00 2001 From: Rob Gridley Date: Thu, 22 Jun 2017 19:17:06 -0400 Subject: [PATCH] Updated readme --- README.md | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 8a7f1e7..db46cdd 100644 --- a/README.md +++ b/README.md @@ -3,16 +3,22 @@ ## Usage ```php use Icewind\SMB\Server; +use Icewind\SMB\NativeServer; use League\Flysystem\Filesystem; use RobGridley\Flysystem\Smb\SmbAdapter; -$server = new Server('host', 'username', 'password'); +if (Server::nativeAvailable()) { + $server = new NativeServer('host', 'username', 'password'); +} else { + $server = new Server('host', 'username', 'password'); +} + $share = $server->getShare('name'); $filesystem = new Filesystem(new SmbAdapter($share)); ``` + ## Installation ``` $ composer require robgridley/flysystem-smb -$ composer update ```