made updateAlert() fun, not working yet