using debug module for debug output, allow to specify a function in plugin option, removed configure option