added showAlert function back into main.js