Some of the hook implementations (most notably hook_commerce_bpc_get_combinations()) are virtually identical between the list.module fields (in commerce_bpc.hooks_list.inc) and the taxonomy reference fields (in bpc_taxonomy.module). In addition, at least some of this overlap will likely be overlapping for many (though not all) kinds of combination-creating modules.

Reduce this duplication by having default implementations that can be called from the proper hook implementations, passing arguments for the few things that vary.

Comments

sven.lauer’s picture

Version: 7.x-1.x-dev » 7.x-2.x-dev

Commerce bpc will use a "core like" release management, meaning that new features will go into the 2.x branch (but might be backported).

sven.lauer’s picture

Title: Refactor the hook implementations for list.module fields and taxonomy reference fields to remove duplication » Refactor API and hook implementations for combination creating fields to target widget types instead of field types