Last active
November 29, 2024 09:57
-
-
Save iamstuartwilson/a54eac64116941990a95 to your computer and use it in GitHub Desktop.
Kill multiple slack files from your browser console. Simply paste this code when on the "https://[space].slack.com/files/[me]" page.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function(){ | |
function killIt(id) { | |
console.log(id); | |
$.post('/api/files.delete', { | |
file: id, | |
token: boot_data.api_token | |
}, function(data) { | |
console.log(data); | |
}); | |
} | |
$('#files_list > [data-file-id]').each(function(i) { | |
killIt($(this).attr('data-file-id')); | |
}); | |
})(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment