removed superflous vaiables in createClosure