Merge pull request #17 from rezzza/php_without_ftp

If ftp extension of php miss, it'll not throw exception
This commit is contained in:
Antoine Hérault 2012-08-02 05:22:48 -07:00
commit ca477696cc

View File

@ -53,7 +53,7 @@ class FtpAdapterFactory implements AdapterFactoryInterface
->booleanNode('passive')->defaultFalse()->end() ->booleanNode('passive')->defaultFalse()->end()
->booleanNode('create')->defaultFalse()->end() ->booleanNode('create')->defaultFalse()->end()
->scalarNode('mode') ->scalarNode('mode')
->defaultValue(FTP_ASCII) ->defaultValue(defined('FTP_ASCII') ? FTP_ASCII : null)
->beforeNormalization() ->beforeNormalization()
->ifString() ->ifString()
->then(function($v) { return constant($v); }) ->then(function($v) { return constant($v); })