finished frontend alerts logic