implemented leaving