Another attempt at handling func_wrapper error