Commit 3e5b0ca4 authored by Robert Lyon's avatar Robert Lyon Committed by Gerrit Code Review

Merge "Bug 1609538: Don't display the alert message if empty"

parents 61dfbe8d 6dc2a95d
......@@ -209,6 +209,9 @@ function makeMessage(message, type) {
* Appends a status message to the end of elemid
*/
function displayMessage(message, type, hideprevmsg) {
if (message === undefined || message == '') {
return;
}
// ensure we have type 'ok', 'error', or 'info' (the default)
if (!type || (type != 'ok' && type != 'error')) {
type = 'info';
......@@ -331,7 +334,7 @@ function sendjsonrequest(url, data, method, successcallback, errorcallback, quie
data = data.message;
}
if (typeof(data.message) === 'string' && !quiet) {
if (typeof(data.message) === 'string' && (data.message != '') && !quiet) {
displayMessage(data.message, error ? 'error' : 'ok');
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment