Make alert and notice conditional