Added completed event + some bug fixes