Improved custom plugin handling