I feel like this is simple.
I have two functions that contain identical code, but need to have different add_actions and arguments. There's got to be a way to do this so I'm not copying and pasting between the two when I want to add more code, plus you're not supposed to duplicate code. What am I missing?
One is for ACF and fires when updating a post type and one is for Admin Columns that fires the same actions but when editing the same post type inline. I have these in a plugin file if that helps.
function acp_editing_saved_usage1( AC\Column $column, $post_id, $value ) {
runs same code
}
add_action( 'acp/editing/saved', 'acp_editing_saved_usage', 10, 3 );
function my_acf_save_post( $post_id ) {
runs same code
}
add_action('acf/save_post', 'my_acf_save_post');