Closed (fixed)
Project:
Imagefield Crop
Version:
6.x-1.0-beta3
Component:
User interface
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
19 May 2009 at 13:28 UTC
Updated:
3 Jan 2014 at 00:29 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
yhager commentedI assumed imageapi will require these, but I've added a note to the README. Thanks!
Comment #2
decipheredThis is only a request, I'm happy for you to leave this issue marked as fixed and ignore the following :)
I consider my self a pretty savvy user, being a module developer and all, but I hit this issue and I didn't even consider looking at the README.txt.
It could pay to use hook_requirements() to add a message/warning/error on install that notifies users of the need to install one of the libraries.
Cheers,
Deciphered.
Comment #3
yhager commentedWell, the README file is there for a reason, and it is named by the action required, in capital letters :).
Nevertheless, I'll accept your offer, as it is never too cautious to make another check. If you can supply a patch (http://drupal.org/patch/create), I'll be happy to include it in, probably faster than I'll implement it myself.
Comment #4
dokumori commentedActually what imageapi tells you is that no toolkit is present so adding the programmatic check is useful. Cheers!
Comment #5
boaz_r commentedthere. a patch for resolving this issue:
when enabling the module, if no toolkits are alive, an error message is displayed and the module is not being enabled.
Comment #6
yhager commented@boaz_r, thanks for the patch.
Isn't hook_requirements() more appropriate in this case? It should take care of the case that the image toolkit is enabled at install time, but disabled later.
Comment #7
boaz_r commentedhook_requirements, "install" phase runs only when installing the module for the first time and possibly (haven't checked it) only if your module has hook_install() implementation. This means that if you install + enable the module, then do god's know what, then disable it. Then enabling it back some time in the future, this time with no toolkit present, with hook_requirements() you wont get any notice about this and the enabling is permitted but the imagefield_crop wont work (this bug).
On the contrary, with my design, no matter what: when enabling the module it checks for presence of at least one imageapi toolkits. None present? imagefield_crop is disabled plus an error message is shown to the administrator.
Feel free to alter my design, of course - you're own imagefield_crop :-)
Comment #8
yhager commentedDeciphered, boaz_r: I have added hook_requirements() implementation for this module. However, note that imageapi, which this module depends on, also have the same hook_requirements implementation. So this should have showed up in your status report anyway (alas without specifically mentioning imagefield_crop).