Fix for loosing function reference when minifying