function acquia_lift_personalize_agent_update_status in Acquia Lift Connector 7
Same name and namespace in other branches
- 7.2 acquia_lift.module \acquia_lift_personalize_agent_update_status()
Implements hook_personalize_agent_update_status().
File
- ./
acquia_lift.module, line 585 - acquia_lift.module Provides Acquia Lift-specific personalization functionality.
Code
function acquia_lift_personalize_agent_update_status($agent_name, $old_status, $status) {
// Clear the agent's verification status.
acquia_lift_agent_clear_verified_status($agent_name);
$agent_data = personalize_agent_load($agent_name);
if (!acquia_lift_is_testing_agent($agent_data)) {
return;
}
$agent_instance = personalize_agent_load_agent($agent_name, TRUE);
if (!$agent_instance instanceof AcquiaLiftAgentInterface) {
return;
}
$agent_instance
->syncAgentStatus();
}