Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save pastak/1cf2be130f8fdadb1879 to your computer and use it in GitHub Desktop.
Save pastak/1cf2be130f8fdadb1879 to your computer and use it in GitHub Desktop.
// ==UserScript==
// @name Remove gmail--c@geafouvgrmtritrge000**.com
// @namespace
// @description
// @include https://inside.kmc.gr.jp/m2w/info*
// ==/UserScript==
var removeSpam = function(){
Array.prototype.slice.apply(document.querySelectorAll('td.from'))
.filter(function(item){
return item.textContent.match(/geafouvgrmtritrge000\w+\.com/)
})
.forEach(function(item){
var tr = item.parentElement;
tr.parentElement.removeChild(tr);
})
}
document.body.addEventListener('DOMNodeInserted',removeSpam);
removeSpam();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment