fix: invalid return from closure (memory fault!!)