-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[zend-file-transfer]: unable to load adapters #11
Comments
some thoughts: as constructor calls which calls
|
the current code ends up calling public function setAdapter($adapter, $direction = false, $options = array())
{
if (Zend_Loader::isReadable('Zend/File/Transfer/Adapter/' . ucfirst($adapter). '.php')) {
$adapter = 'Zend_File_Transfer_Adapter_' . ucfirst($adapter);
}
if (!class_exists($adapter)) {
Zend_Loader::loadClass($adapter);
} |
looks like I missed that one... it should probably be: (similar to the changes in https://github.com/zf1s/zf1/blob/1.13.0/packages/zend-translate/library/Zend/Translate.php#L130) if (class_exists('Zend_File_Transfer_Adapter_' . ucfirst($adapter)) {
$adapter = 'Zend_File_Transfer_Adapter_' . ucfirst($adapter);
} elseif (!class_exists($adapter)) {
Zend_Loader::loadClass($adapter);
} ... and zend-loader dependency should be probably added to the composer.json anyway |
was not sure what was the purpose of the |
ok, updated #12; however the code now runs without "zf1s/zend-loader" (see |
oh, btw, don't link to branches! |
ironically, I don't even need to use that component. it was loaded but never used in the codebase. so no pressure from my side to get this released :D |
I am going to wait a bit with the next release, in case of other issues occur in the meantime, to avoid bumping versions for all components too often. If anyone needs to use this please switch to |
and as you said you missed this one: #11 (comment) should probably inspect codebase for more of the adapter loading and check their compatibility. |
given code:
with
zf1s/zend-file-transfer
installed, i get error:loading
"zf1s/zend-loader"
, the error changes to:I've created gist to play around with:
https://gist.github.com/glensc/ce6a301ddc60a0d1dba8878ae32709c3
with git tags
v1
andv2
respectively for the tests.The text was updated successfully, but these errors were encountered: