[ticket/12572] Fix JS error when alert message title is undefined

JS console reports error in core.js:
TypeError: alert is undefined
alert.hide()
when res.MESSAGE_TITLE is undefined.

<a href="https://tracker.phpbb.com/browse/PHPBB3-12572">PHPBB3-12572</a>.