Revert "If the page doesn't have .notices, silently skip the notice XHR response"

This reverts commit 7b550f386a.
This commit is contained in:
Sarven Capadisli 2009-12-02 23:25:38 +01:00
parent 5963c140d6
commit 62d5f05669

View File

@ -214,9 +214,6 @@ var SN = { // StatusNet
self.close();
}
var notices = $("#notices_primary .notices");
if (notices.length > 0) {
if ($('#'+SN.C.S.CommandResult, data).length > 0) {
result = document._importNode($('p', data)[0], true);
result = result.textContent || result.innerHTML;
@ -234,7 +231,7 @@ var SN = { // StatusNet
$($(notice_irt+' .notices')[0]).append(notice);
}
else {
notices.prepend(notice);
$("#notices_primary .notices").prepend(notice);
}
$('#'+notice.id).css({display:'none'});
$('#'+notice.id).fadeIn(2500);
@ -249,7 +246,6 @@ var SN = { // StatusNet
$('#'+form_id+' #'+SN.C.S.NoticeDataAttachSelected).remove();
SN.U.FormNoticeEnhancements($('#'+form_id));
}
}
},
complete: function(xhr, textStatus) {
form.removeClass(SN.C.S.Processing);