Fixed onAdd/onRemove methods and created example