Needs work
Project:
Apps
Version:
7.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
8 May 2013 at 20:48 UTC
Updated:
22 Jun 2016 at 08:37 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
roam2345 commentedupdate title better description.
Comment #2
roam2345 commentedHere is a patch, not the callback on the disable was missing.
according to the API this should be called there as well. 'post install callback' => 'appname_app_post_install', // This will be called after the app is enabled intialy or of the app has been uninstalled
Comment #3
roam2345 commentedComment #4
roam2345 commentedthe call to the 'post install callback' is firing for the disable function however the enable it is still not i have looked up and found that the clear cache all usage before these callbacks are called should also change to use the system_rebuild_module_data() function.
Comment #5
roam2345 commentedRight this now correctly gets the callback firing on module enable / disable.
Comment #6
roam2345 commentedHad the callback firing on the wrong hook, according to the api wording, also fixed white space. "// This will be called after the app is enabled intialy or of the app has been uninstalled"
Comment #7
roam2345 commentedWe needed more hooks on the app enable / disable / uninstall process.
I have gone a head and added two new ones and documented them in the API as well.
Comment #8
mrfelton commentedPatch slightly updated for latest apps version.
Comment #9
hefox commented+ // Else try load this module (happens when module is not enabled)
+ if (isset($app['machine_name']) && !empty($key)) {
+ module_load_include("module", $app['machine_name']);
+ $info = module_invoke($app['machine_name'], 'apps_app_info');
+ if (isset($info[$key]) && function_exists($info[$key])) {
+ return $info[$key];
+ }
+ }
(dreditor not working for me atm!)
So, I can't reproduce needing to recall apps_app_info -- the way it gets the info works fine for disabled apps.
Comment #10
hefox commentedComment #11
amuhebwa commentedI hadn't seen this issue, i shouldn't have replicated it. but here is the link with a patch https://www.drupal.org/node/2376519#comment-9370591
Comment #12
berdyshev commented@hefox, @mrfelton, The app info is not loaded during distribution installation process because drupal is not fully bootstrapped. But, I think instead of this invocation of
hook_apps_app_info()inapps_app_callback()it is better to do this when it should be done inapps_add_app_info(). See the issue #2753413: app_manifest() could not call hook_apps_app_info()