Added suggested fix with unnecessary intermediate closure