Filtering Autosuggest Field

Hey there! I’ve got a question on properly filtering the get_autosuggest_values function from class-fl-builder-auto-suggest.php. I’ve successfully added my own custom action fl_as_hubspot in the fl_builder_autosuggest function and that successfully makes an API call and returns the proper data. However, whenever I go to edit the page where I’ve embedded this module and go to change the settings, what normally shows the name of the post if I use posts, just shows a blank value in the module.

I see that the default case for get_value in class-fl-builder-auto-suggest.php should call my action_value function if my function exists. I’ve put a hubspot_value function into a helper file that loads bare classes as everything else in my custom plugin is class-based.

Is there an example anywhere on how I can short circuit the get_value function properly to make my API call so that I can get the data from the API I need?

Hey! Any solution for this? A simple filter in the get_value function would do the trick.

A hack would be to define the actions as a namespace + class + partial method so call_user_func_array( $action . '_value', array( $value, $data ) ) would do something like call_user_func_array( 'Some\\Namespace\\MyClass::get_something' . '_value', array( $value, $data ) ) but that’s ugly…